From patchwork Thu Dec 12 07:53:29 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Georgi Djakov X-Patchwork-Id: 181453 Delivered-To: patch@linaro.org Received: by 2002:a92:3001:0:0:0:0:0 with SMTP id x1csp563572ile; Wed, 11 Dec 2019 23:53:39 -0800 (PST) X-Google-Smtp-Source: APXvYqw/6JhxULTULHI8WFoUz2ulaMJHuJsKj/ZNzoJT4Y45yXftHOSazBbRomdWqasaprqzKLTm X-Received: by 2002:a05:6830:18d7:: with SMTP id v23mr6387621ote.213.1576137219505; Wed, 11 Dec 2019 23:53:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1576137219; cv=none; d=google.com; s=arc-20160816; b=NaDOvKfIrSvNCTP6eWQ8JyTIi544ilK7xuYpq4CwF650UUnSNwt58SShFD6/bagcly Yo63gpQdBzSfZtwEfM2SrYoqHQt+QKhVc4TlXDO/lWoZZTfgX/oF/kArk+aVNGxfHX80 he7s/SnCub5CFP+LdqOCAlJAKkpQMZYdLy+b9KgD2n88LPfG1i7BxmfTFl0VSG1ovZ6J sjeXDD+gBKp/uAUvs6Mil6sIojGMv+5QQ+p6QczpgfGJu7mx2WMccgBIXFJ1iCPWyo8D aXrlMbrGfjcUkdOzXC0CTKIPi5DALTXdqiTexfd8Iv2IfdqLFT2VC9SidT9wBJ1fRGvD H63A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=V2BxefIfBzald1w3B2qVq4/Mnrw+MpcEMXquUNshwCQ=; b=adAmXnwu0ww3iRTN3U0sZq7+V87KMnJIQlINUlOlN3RAqLGbIPJj0QwoCwxCRGRVYO NTJiyOJJpA4rFRXeZSS8OegbR21wkKAhGMwgdpK4jnv+mriyjRZ01/tCF1raMY64I8ZS JD4RHh5LMdL+kWMDymVsYX9o67EXrmqX6lLSUGYSrqcf6oo3HFIWHgC2ebNWontc1dvv OFahWkC23cMkx2jjS4uUscrqZ3DoHWbpfAGMiRawwtVM0WXKVpUE2q2AgVuG+MTx/0d2 n8J1BvAQyKqUJwpQr+3Od/m8VYspFSTmrrL7L8DbzXFPw6qeHbcqC4cJu6HPRjA1ZjgX jHhQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=a4AiFZYK; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b133si2826922oii.155.2019.12.11.23.53.39; Wed, 11 Dec 2019 23:53:39 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=a4AiFZYK; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728201AbfLLHxi (ORCPT + 27 others); Thu, 12 Dec 2019 02:53:38 -0500 Received: from mail-wr1-f65.google.com ([209.85.221.65]:33491 "EHLO mail-wr1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728099AbfLLHxg (ORCPT ); Thu, 12 Dec 2019 02:53:36 -0500 Received: by mail-wr1-f65.google.com with SMTP id b6so1640676wrq.0 for ; Wed, 11 Dec 2019 23:53:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=V2BxefIfBzald1w3B2qVq4/Mnrw+MpcEMXquUNshwCQ=; b=a4AiFZYKsCKuIL2IwNdbbxZROXHMrl0otYb2KrvVl67D12pLPV5ToyhpKan9Lxwtah zH1gICMj5/TgwKYMz8rWYAhYkLvFbaPf+luFG2MN5OByqzHGjLFCO6jUb1mHIpFKSV0u NenALf80YXM6faIkMBsbpQTDtBl9DXbMpEN68aCSq3LQnsHuReU6Jw9N95tQCefPGNlc PBwSpPEIKTCZpv1jsB83030xy8Q3KSxZSEkCYRXBDp+AL3DLG+hO7GJISuPb1F7idq1g vTM4t4sbLHCvOFISPXgWfKf7PE8DxMboCIjJgetj1XObhZqr3gaP/61Kfxs4QR8I97/Y cwWQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=V2BxefIfBzald1w3B2qVq4/Mnrw+MpcEMXquUNshwCQ=; b=OQimnbL2ml/wKxS2BMVWXinagvAIAxk7hwyfcvWmACWBBUo9Ke79fFq8d1VTSYYxIW 1L5pDi1PH6IOSF7oJ4ZyoiG+u/5RSYgGXI/7t2K/++Jh154U6XW1GyEKRwLx3svi4fMd ADnzndu2yHutKCUeNgbEvqIDg3srEV5CUGj4CRI94NiVyqVEfspbBZLnWUisRwFmbKBl T5C9XM68aZVSX/eqvhCNMGL7LXqJRrjXU7n3t//lat85ulH+W+I255SBkrQKWa3RUSAQ IHr/PshLjrFgtjR9IhlYFt4W4aTTSXvIqvG4yLbfs+FiETooXEwv412ffZCteFb8yvhh 1A7w== X-Gm-Message-State: APjAAAW9Jgh4LVxoN4PewyT4RJlvTDBhhL87cqPuPDQOxwKZuNyOY9DQ euq9RsJc3r7BSPbrTUgfUSCylOA6SyE= X-Received: by 2002:a5d:6b82:: with SMTP id n2mr4544132wrx.153.1576137214539; Wed, 11 Dec 2019 23:53:34 -0800 (PST) Received: from localhost.localdomain ([212.45.67.2]) by smtp.googlemail.com with ESMTPSA id x6sm5636742wmi.44.2019.12.11.23.53.33 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 11 Dec 2019 23:53:34 -0800 (PST) From: Georgi Djakov To: gregkh@linuxfoundation.org Cc: linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, Krzysztof Kozlowski , Georgi Djakov Subject: [PATCH 1/4] interconnect: qcom: Fix Kconfig indentation Date: Thu, 12 Dec 2019 09:53:29 +0200 Message-Id: <20191212075332.16202-2-georgi.djakov@linaro.org> X-Mailer: git-send-email 2.24.0 In-Reply-To: <20191212075332.16202-1-georgi.djakov@linaro.org> References: <20191212075332.16202-1-georgi.djakov@linaro.org> MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Krzysztof Kozlowski Adjust indentation from spaces to tab (+optional two spaces) as in coding style with command like: $ sed -e 's/^ /\t/' -i */Kconfig Signed-off-by: Krzysztof Kozlowski Signed-off-by: Georgi Djakov --- drivers/interconnect/qcom/Kconfig | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/interconnect/qcom/Kconfig b/drivers/interconnect/qcom/Kconfig index c49afbea3458..2f9304d1db49 100644 --- a/drivers/interconnect/qcom/Kconfig +++ b/drivers/interconnect/qcom/Kconfig @@ -6,13 +6,13 @@ config INTERCONNECT_QCOM Support for Qualcomm's Network-on-Chip interconnect hardware. config INTERCONNECT_QCOM_MSM8974 - tristate "Qualcomm MSM8974 interconnect driver" - depends on INTERCONNECT_QCOM - depends on QCOM_SMD_RPM - select INTERCONNECT_QCOM_SMD_RPM - help - This is a driver for the Qualcomm Network-on-Chip on msm8974-based - platforms. + tristate "Qualcomm MSM8974 interconnect driver" + depends on INTERCONNECT_QCOM + depends on QCOM_SMD_RPM + select INTERCONNECT_QCOM_SMD_RPM + help + This is a driver for the Qualcomm Network-on-Chip on msm8974-based + platforms. config INTERCONNECT_QCOM_QCS404 tristate "Qualcomm QCS404 interconnect driver" From patchwork Thu Dec 12 07:53:31 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Georgi Djakov X-Patchwork-Id: 181454 Delivered-To: patch@linaro.org Received: by 2002:a92:3001:0:0:0:0:0 with SMTP id x1csp563592ile; Wed, 11 Dec 2019 23:53:41 -0800 (PST) X-Google-Smtp-Source: APXvYqyUIkzOfaBwnRCS1K9TWlk2qeipKoMTrzEo1CJP9qv8oFXamAebyX2emw41hH6pDmixagZS X-Received: by 2002:a9d:70cb:: with SMTP id w11mr6861064otj.157.1576137221250; Wed, 11 Dec 2019 23:53:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1576137221; cv=none; d=google.com; s=arc-20160816; b=OHcctxYFNOFcDppF/4WPdU4JIvrxMTBE3lVEUnT+Uuzo/tHwZEKK0d+LWnB09H8dRP oZ46uCw0YEzRumSdzX2cjfUIoRmrZMTRvoAHL0V6Y1Tf7Y2FBRPm0mplAaj6L8ws2KlE 4XmThazbJtBqRhpqhuQmQskzLWiDX/W1D7IEGygJfhYeCBFIjcuEjfnMZigBpinEJsis P351za3UsrMw3dKmwq/XdhxDOQEq0Hu4nYlxpjNcXXPC+PYZB4mnUFTDXioGOHH3aiW+ CyK22lolOz4yFKzRP+fyeC5v1N1fRDbAJkK5YvxqKVZPeby59HTMOiRpDQMtklOILd/K gOkQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=/ok0nQnxyVp+hWourd2iRYkQMDbNDd797Oi+3MDLgvE=; b=ubE5WnP5EDcdspOnBwY4zck4c9nCbQyDB27+Ft9AoN8j2C47IUQhm0lgn9GU5aPBF4 cOLiBCvgJixEGUsNlfibqEWW0MOsymZ7dtRD270XKcp1j99Xt7rtwo8nuyVGIpbOqENt yQDds/h2ml+OvIkBi6Fnnvvhbv459oYTOhpzSYrXYB2nsXyN1BvafsJKbenRVqP4XjO3 MqtQYuBGO48l+TyJVpSQIZtncLuKoyJA0BrzwrMNMPLOl26qH2q4KsRObFQMm1LljfMJ +IKB5eEroXcmqC6+MKZ+Kc62AYHOJ6RnKFocrmI+mBY6Q0mNP0e99Za9TtkUwnDFF9dY INLg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=kuBwZF3a; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b133si2826922oii.155.2019.12.11.23.53.41; Wed, 11 Dec 2019 23:53:41 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=kuBwZF3a; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728190AbfLLHxk (ORCPT + 27 others); Thu, 12 Dec 2019 02:53:40 -0500 Received: from mail-wr1-f66.google.com ([209.85.221.66]:34692 "EHLO mail-wr1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728191AbfLLHxi (ORCPT ); Thu, 12 Dec 2019 02:53:38 -0500 Received: by mail-wr1-f66.google.com with SMTP id t2so1630057wrr.1 for ; Wed, 11 Dec 2019 23:53:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=/ok0nQnxyVp+hWourd2iRYkQMDbNDd797Oi+3MDLgvE=; b=kuBwZF3aTUHamxKahISgDPfpkTVxpBWPErTUxDu8tvilS/xaRc3rm9NfU4I6x4KXsZ ZstbdCSaaVFHD07vHcFFvZRa6afY74PXr4bIkBz7g3Tlel5xeUfBh1nGCq4vaGK1US5W EPmSF9L41f5LHog3fQib1Q3H4aTGpyh1uQn5pLKvx5bday1E3nvG8tXShjGW507ItW4X dHMRdOEhHXXNCmKe8jA6j4ZxIec/a2dDFUPoLSeCc/kcwNXRlE3cmUXidsrOcFLm3Wss 0Vfrm+hMFh/WZF3hckaFO9jIIEklzubZWt7sSLrhO8VjiS9j/gPtkwA2/cWqiJhfs32i NoZQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=/ok0nQnxyVp+hWourd2iRYkQMDbNDd797Oi+3MDLgvE=; b=WQdCZZg7fC2zngd546ulaA/FCIUo6x2T6u8bqIjOzv3jnJAErmO3zQ4+sLqDDQgIo3 eDDD6FdoSd95CKkdnPBQBqRf+qy/6y2+d0zgTOKIrV0EigGGTih7n22iWTLQWBpl7Tul GpvOf9Nk5i82rJd1ri7Q5CFtXBUIv2MfaN6earnMTS9AeLkpuVDyiuOzcIqck6NZ1K4L TaEtGpScq6+kfmh0xTRD+A+jNn3VfgOYL0mfmCyVkfbEaL8zT1aOSXFTWO0AbCk9Coe6 eC54DIDh/QIyRnoEZhSqkqUuOpEw0um7W+mr9+yueBxdAw1O30Njcj+ohHtGmUdMApN2 Xjwg== X-Gm-Message-State: APjAAAW0Gvse6rymQWwF2OLLb8KoiaGt4mvGj+ZCRfD6uvtZa9yweO+B WHsQEjhirVMZXO8z+16dJ+qTWQ== X-Received: by 2002:adf:f10a:: with SMTP id r10mr4623170wro.202.1576137216719; Wed, 11 Dec 2019 23:53:36 -0800 (PST) Received: from localhost.localdomain ([212.45.67.2]) by smtp.googlemail.com with ESMTPSA id x6sm5636742wmi.44.2019.12.11.23.53.35 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 11 Dec 2019 23:53:36 -0800 (PST) From: Georgi Djakov To: gregkh@linuxfoundation.org Cc: linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, Georgi Djakov , Dmitry Osipenko , Bjorn Andersson , stable@vger.kernel.org Subject: [PATCH 3/4] interconnect: qcom: qcs404: Walk the list safely on node removal Date: Thu, 12 Dec 2019 09:53:31 +0200 Message-Id: <20191212075332.16202-4-georgi.djakov@linaro.org> X-Mailer: git-send-email 2.24.0 In-Reply-To: <20191212075332.16202-1-georgi.djakov@linaro.org> References: <20191212075332.16202-1-georgi.djakov@linaro.org> MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org As we will remove items off the list using list_del(), we need to use the safe version of list_for_each_entry(). Fixes: 5e4e6c4d3ae0 ("interconnect: qcom: Add QCS404 interconnect provider driver") Reported-by: Dmitry Osipenko Reviewed-by: Bjorn Andersson Signed-off-by: Georgi Djakov Cc: # v5.4 --- drivers/interconnect/qcom/qcs404.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/interconnect/qcom/qcs404.c b/drivers/interconnect/qcom/qcs404.c index b4966d8f3348..8e0735a87040 100644 --- a/drivers/interconnect/qcom/qcs404.c +++ b/drivers/interconnect/qcom/qcs404.c @@ -414,7 +414,7 @@ static int qnoc_probe(struct platform_device *pdev) struct icc_provider *provider; struct qcom_icc_node **qnodes; struct qcom_icc_provider *qp; - struct icc_node *node; + struct icc_node *node, *tmp; size_t num_nodes, i; int ret; @@ -494,7 +494,7 @@ static int qnoc_probe(struct platform_device *pdev) return 0; err: - list_for_each_entry(node, &provider->nodes, node_list) { + list_for_each_entry_safe(node, tmp, &provider->nodes, node_list) { icc_node_del(node); icc_node_destroy(node->id); } @@ -508,9 +508,9 @@ static int qnoc_remove(struct platform_device *pdev) { struct qcom_icc_provider *qp = platform_get_drvdata(pdev); struct icc_provider *provider = &qp->provider; - struct icc_node *n; + struct icc_node *n, *tmp; - list_for_each_entry(n, &provider->nodes, node_list) { + list_for_each_entry_safe(n, tmp, &provider->nodes, node_list) { icc_node_del(n); icc_node_destroy(n->id); }