From patchwork Thu Oct 3 15:53:00 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg Kroah-Hartman X-Patchwork-Id: 175086 Delivered-To: patch@linaro.org Received: by 2002:a92:7e96:0:0:0:0:0 with SMTP id q22csp510988ill; Thu, 3 Oct 2019 08:57:22 -0700 (PDT) X-Google-Smtp-Source: APXvYqwvAVb2RQvTt5PLE98HJiVlLKcqtvtDhSKBjw+b/AxNpYXfLKwi0PB3PPVsddLIjlxJ8NIi X-Received: by 2002:a17:906:2542:: with SMTP id j2mr8466565ejb.278.1570118242027; Thu, 03 Oct 2019 08:57:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570118242; cv=none; d=google.com; s=arc-20160816; b=n0tgTgYe5BPMxYL4kd3SX/l0c890C9aaivlbUJD8cKGFHMHmqZ5/355wLRTS6DcGQk 10a/Oe9uFIbvW4y1FO8uDL797/UDPLi3opDcrvpfDbcI98M/vQfezvt1ZsFU/8wiUJPD aleXPh014/htmi5/yw+kMV58EjTK2+nK0F1sdN/BIdfHCi5AIZGmxNkaGiBpJpPgjWeY TKzg/a+8tv5iHR26cHWjy4jIHr5rTY4OqwINRb79v2TtKS+B8LpFvvn8Zpzldjo1OIh/ DkaFMqSXiPBTuR3pW+puIXftjXJ6tMrSvsdfHoDiSQ4VpNhh+mjwrHJ/VvcdLCeBQRgd hw4A== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=PIfJhvcYMth2WDkz1jmHhz+yPHt2EDTaxIPKTCMwKRw=; b=0yo8J92/9YZVVGzWXJUSMyuZAgFrvZF7Y1vjQj7V+QZoawaTSp9wiFwcdpfBLD/n0x l6I2wFh2bjhBpJFPTmg2iCU+Rbw8U/pSFa6kvN/7UQAW4tMwcecVk+zarFImNi8z1We3 iTep5Q/xCXsJzdpT11GAHvXT+7iLiW+GTQE/TnXXCQl8edTlW2kU6o2xpuah5jmoU4p/ uYPW1s4gvAngsYrsGsiw/KzGsvXveemCGnuaEo7+AZgM9iMAq57yRsuR/A5Ej95WwgeP /Dd4oIn1NFrCJAuCkHmPoE2qcalgVtr+zdXchzBdL2yxjCQDaEQIe++bGTKiidf7Zscv a6ug== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=BD2Ks0nZ; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y54si1972024edb.217.2019.10.03.08.57.21; Thu, 03 Oct 2019 08:57:22 -0700 (PDT) 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=@kernel.org header.s=default header.b=BD2Ks0nZ; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730923AbfJCP5U (ORCPT + 27 others); Thu, 3 Oct 2019 11:57:20 -0400 Received: from mail.kernel.org ([198.145.29.99]:39624 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726863AbfJCP5Q (ORCPT ); Thu, 3 Oct 2019 11:57:16 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id B99EB21783; Thu, 3 Oct 2019 15:57:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1570118236; bh=R1bNk2/hCaKw1ytY+Ws4ld/IUdVpxotA409O+wn8ryo=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=BD2Ks0nZNR0MU+cY+KTrkfg9z1f3MjHsfuNn7WZkKXOUGGTOzR20gmjlv09wT4+VT 7JmAYQh1REYxvRYc5EzDAimeqwA7+hnGK3PPDpKE6rK4DXHEFJ8YBEigQI+CebdrXA uZpnkCYZMiT15fTz5KyRe5xaI4zsfIUIOJIbCMPI= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Arnd Bergmann , Sean Young , Mauro Carvalho Chehab , Sasha Levin Subject: [PATCH 4.4 37/99] media: dib0700: fix link error for dibx000_i2c_set_speed Date: Thu, 3 Oct 2019 17:53:00 +0200 Message-Id: <20191003154313.072250631@linuxfoundation.org> X-Mailer: git-send-email 2.23.0 In-Reply-To: <20191003154252.297991283@linuxfoundation.org> References: <20191003154252.297991283@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Arnd Bergmann [ Upstream commit 765bb8610d305ee488b35d07e2a04ae52fb2df9c ] When CONFIG_DVB_DIB9000 is disabled, we can still compile code that now fails to link against dibx000_i2c_set_speed: drivers/media/usb/dvb-usb/dib0700_devices.o: In function `dib01x0_pmu_update.constprop.7': dib0700_devices.c:(.text.unlikely+0x1c9c): undefined reference to `dibx000_i2c_set_speed' The call sites are both through dib01x0_pmu_update(), which gets passed an 'i2c' pointer from dib9000_get_i2c_master(), which has returned NULL. Checking this pointer seems to be a good idea anyway, and it avoids the link failure in most cases. Sean Young found another case that is not fixed by that, where certain gcc versions leave an unused function in place that causes the link error, but adding an explict IS_ENABLED() check also solves this. Fixes: b7f54910ce01 ("V4L/DVB (4647): Added module for DiB0700 based devices") Signed-off-by: Arnd Bergmann Signed-off-by: Sean Young Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Sasha Levin --- drivers/media/usb/dvb-usb/dib0700_devices.c | 8 ++++++++ 1 file changed, 8 insertions(+) -- 2.20.1 diff --git a/drivers/media/usb/dvb-usb/dib0700_devices.c b/drivers/media/usb/dvb-usb/dib0700_devices.c index 38c03283a4417..e1316c7b7c2e5 100644 --- a/drivers/media/usb/dvb-usb/dib0700_devices.c +++ b/drivers/media/usb/dvb-usb/dib0700_devices.c @@ -2418,9 +2418,13 @@ static int dib9090_tuner_attach(struct dvb_usb_adapter *adap) 8, 0x0486, }; + if (!IS_ENABLED(CONFIG_DVB_DIB9000)) + return -ENODEV; if (dvb_attach(dib0090_fw_register, adap->fe_adap[0].fe, i2c, &dib9090_dib0090_config) == NULL) return -ENODEV; i2c = dib9000_get_i2c_master(adap->fe_adap[0].fe, DIBX000_I2C_INTERFACE_GPIO_1_2, 0); + if (!i2c) + return -ENODEV; if (dib01x0_pmu_update(i2c, data_dib190, 10) != 0) return -ENODEV; dib0700_set_i2c_speed(adap->dev, 1500); @@ -2496,10 +2500,14 @@ static int nim9090md_tuner_attach(struct dvb_usb_adapter *adap) 0, 0x00ef, 8, 0x0406, }; + if (!IS_ENABLED(CONFIG_DVB_DIB9000)) + return -ENODEV; i2c = dib9000_get_tuner_interface(adap->fe_adap[0].fe); if (dvb_attach(dib0090_fw_register, adap->fe_adap[0].fe, i2c, &nim9090md_dib0090_config[0]) == NULL) return -ENODEV; i2c = dib9000_get_i2c_master(adap->fe_adap[0].fe, DIBX000_I2C_INTERFACE_GPIO_1_2, 0); + if (!i2c) + return -ENODEV; if (dib01x0_pmu_update(i2c, data_dib190, 10) < 0) return -ENODEV; From patchwork Thu Oct 3 15:53:02 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg Kroah-Hartman X-Patchwork-Id: 175192 Delivered-To: patch@linaro.org Received: by 2002:a92:7e96:0:0:0:0:0 with SMTP id q22csp646590ill; Thu, 3 Oct 2019 10:42:26 -0700 (PDT) X-Google-Smtp-Source: APXvYqyctbuTHQhLn1gRj+l3bLQ8t1kMwT2VQYexOYyHVFAbTle8F6Sp87/gyMeu/zG4w4O+IDhX X-Received: by 2002:a17:906:254d:: with SMTP id j13mr8762157ejb.30.1570124546647; Thu, 03 Oct 2019 10:42:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570124546; cv=none; d=google.com; s=arc-20160816; b=iQdtun8us7eP6oLIrRzvr1w75PaycAb7Qy7OBtUulEoutXo4xz3wPJqoj+rUhh8Bgg Py+uxus2mt6CrlmGX6tSg8b0aKqqmaCwtFyyBqsNotMQDKgA+XR/O8F8i39rTJQPZGdG BRDI+TaEY7fIvQLIFLB4pmvTA+EsmqNGhAYZy6ch4YUGbHVs4hKRADCCQ61abWE+/Qck n8hPhSMDfD37jgAPC/zP3iId++YCaz9iWuFZEMEboRqleVEyazzB9Gx0GDZcbKdF6R9p 1Si8TaxOTvNKNO1KDjwuil/PnyH6opo4s5xl8vudbspKmZSNgusbmOscpbcGq0SceW8g bTCg== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=UnquXKNgTV2CJDncBb3DRpTBwtw8JEQ6MZf2vyTf1Rk=; b=iWgHT9hKSBNYCt5uAFckkis+fncvOEmC1m6eXtMrkQJn+I5xf2V043+fmGA96+HKNT kPzJXlR6CcwXA874QS7K+zYQXGC9y4BValbfo1UuZh8zIXJx+Yno0WWPqhrmTmeOw5TX 2VRmdeUAyZsWcYK4quYYxwwiqonhzQ5K6Zt8e4jfvVCEAwmo4wKWC89v4l3PHmyMHj9B jwCVgNstWY8G21v0I88oPKBZIrMVcV8cLRiDJqILjkkhAmwuUEKaHQIXR8ONnqVm6GMT p4nGsshKt96+/1sdR6+gh0mXbS14EpNCFJ4G5yJ3UgiWy3gpQofPK1spr1eGE9QXmijS 1p4A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=IGqME5eC; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u12si1947383edi.326.2019.10.03.10.42.26; Thu, 03 Oct 2019 10:42:26 -0700 (PDT) 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=@kernel.org header.s=default header.b=IGqME5eC; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2390463AbfJCRmY (ORCPT + 27 others); Thu, 3 Oct 2019 13:42:24 -0400 Received: from mail.kernel.org ([198.145.29.99]:39716 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730924AbfJCP5W (ORCPT ); Thu, 3 Oct 2019 11:57:22 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 30C5220830; Thu, 3 Oct 2019 15:57:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1570118241; bh=5u9Whsc6p/XfD9xIRZ6kTcBX2xjj+4JbTk+wCWZ59AA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=IGqME5eC9/Wb1MRfQfL+v3vLhoSqf0yP5Bc/6GZqbLUzq3Rl3399VF93s1an+KDgC kpaIv7RulDxaC5Puexa70c8mSP+6zi2CnALWLGe8/+EDfx6ymePbga3IyAPOGOWBBt Qk/NdkN1kTjaTfHAxvs008wPeHdMsL8cNb/734Fs= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Vincent Guittot , "Peter Zijlstra (Intel)" , Linus Torvalds , Thomas Gleixner , Ingo Molnar , Sasha Levin Subject: [PATCH 4.4 39/99] sched/fair: Fix imbalance due to CPU affinity Date: Thu, 3 Oct 2019 17:53:02 +0200 Message-Id: <20191003154314.415611606@linuxfoundation.org> X-Mailer: git-send-email 2.23.0 In-Reply-To: <20191003154252.297991283@linuxfoundation.org> References: <20191003154252.297991283@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Vincent Guittot [ Upstream commit f6cad8df6b30a5d2bbbd2e698f74b4cafb9fb82b ] The load_balance() has a dedicated mecanism to detect when an imbalance is due to CPU affinity and must be handled at parent level. In this case, the imbalance field of the parent's sched_group is set. The description of sg_imbalanced() gives a typical example of two groups of 4 CPUs each and 4 tasks each with a cpumask covering 1 CPU of the first group and 3 CPUs of the second group. Something like: { 0 1 2 3 } { 4 5 6 7 } * * * * But the load_balance fails to fix this UC on my octo cores system made of 2 clusters of quad cores. Whereas the load_balance is able to detect that the imbalanced is due to CPU affinity, it fails to fix it because the imbalance field is cleared before letting parent level a chance to run. In fact, when the imbalance is detected, the load_balance reruns without the CPU with pinned tasks. But there is no other running tasks in the situation described above and everything looks balanced this time so the imbalance field is immediately cleared. The imbalance field should not be cleared if there is no other task to move when the imbalance is detected. Signed-off-by: Vincent Guittot Signed-off-by: Peter Zijlstra (Intel) Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Link: https://lkml.kernel.org/r/1561996022-28829-1-git-send-email-vincent.guittot@linaro.org Signed-off-by: Ingo Molnar Signed-off-by: Sasha Levin --- kernel/sched/fair.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) -- 2.20.1 diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c index 19d735ab44db4..cd2fb8384fbe3 100644 --- a/kernel/sched/fair.c +++ b/kernel/sched/fair.c @@ -7313,9 +7313,10 @@ static int load_balance(int this_cpu, struct rq *this_rq, out_balanced: /* * We reach balance although we may have faced some affinity - * constraints. Clear the imbalance flag if it was set. + * constraints. Clear the imbalance flag only if other tasks got + * a chance to move and fix the imbalance. */ - if (sd_parent) { + if (sd_parent && !(env.flags & LBF_ALL_PINNED)) { int *group_imbalance = &sd_parent->groups->sgc->imbalance; if (*group_imbalance) From patchwork Thu Oct 3 15:53:09 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg Kroah-Hartman X-Patchwork-Id: 175091 Delivered-To: patch@linaro.org Received: by 2002:a92:7e96:0:0:0:0:0 with SMTP id q22csp513489ill; Thu, 3 Oct 2019 08:59:32 -0700 (PDT) X-Google-Smtp-Source: APXvYqzgUZcn9mdWPaLauTBg42VcFYa5hRE8sLatE86RTf07YA6+Kwum3sol83TNDk8YbKGm6yFQ X-Received: by 2002:a17:906:52d8:: with SMTP id w24mr8164635ejn.6.1570118372401; Thu, 03 Oct 2019 08:59:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570118372; cv=none; d=google.com; s=arc-20160816; b=E/66/Wh9M4rNdABpE4GtBCMyFpRLECyAZZzSVXPm/NMeMXa6vfXCrQlMf96miur6v7 n0bHdpyQkeXXXpX1a7DBI6xhlmcqNMVZG11tCP2V+znRRrB96OA3unk6WRDecF63V2jD BXpAPeJp5od8XjY+D+/hfvPJ1ahA7dCFDh22qj1qEErTTxKcPYvtHncOOYkDEw8lVF/p 8dMf/Wfzyr5637HyHQO95dR1B5Na67fu+TD5hq9LMn70QRWbrMS+E3Br2rLTcm4tQbZz WV7yHimBaeX85rSz6BTG3Eotue7ZwHIpR99v0RH+aAi3P0TzUm/g9zet6h8a+QD4ubCI hD4Q== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=RnDhXx02SrCu6XwOHrYH4KUY2Iy3oVs3nXgSpN6KHtk=; b=xP05RLmM5HrT0aKNs7SVwfwUvkq9P8BaGazikkaIF8YRBpBnkgpNfxMkbostVzs2Ox RRPf/kQqE7bcDjHZj+CVukHP2eJ3+23DnvDrJMxBCNcIhRX6Ior/Z/NcWX2wK7BfdMtX wp5LtE3be45Fl0mnGU8cRMqZLMm525UOKH2Tl3rc7x8ii2dcMMZ7zO+7KTsvWaq+oGnB ibg+GpbhWg/6ohjFWyVKzt3uA0fZP+2pbvaNmmN5bzP67d/CySQGx6nscSkuPiJwg+VG 4GGjQD+XVcgVYbDBBx7P2J/Xklh9dIeSEQvN9wb2T28atC7n/3hPn6RoLB1CEtT8F0q0 IVqw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=oB2PQjh1; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id k5si1435133ejp.157.2019.10.03.08.59.32; Thu, 03 Oct 2019 08:59:32 -0700 (PDT) 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=@kernel.org header.s=default header.b=oB2PQjh1; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731345AbfJCP7b (ORCPT + 27 others); Thu, 3 Oct 2019 11:59:31 -0400 Received: from mail.kernel.org ([198.145.29.99]:42418 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731178AbfJCP7Z (ORCPT ); Thu, 3 Oct 2019 11:59:25 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id EA2AC20700; Thu, 3 Oct 2019 15:59:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1570118364; bh=nr9hoKbScMqg1mc7m9e/Fq+wOO542/kklUkiHIoAWZw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=oB2PQjh1MRIVoUbutHyjFg45e3Y2PDDH1KvICXlzfPIf4W91p8NJZez3hoOuRhOfw cLpoyDxtvnx7UKDt8Y1mKil+0HCw80FF9+hUyi4nTcLqeZd01o6B+J8P0gLQKoqfh1 KAeknCFYo2TYKcJzj2T2zMEOu+otoutGXhr6Ih6Y= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Vinod Koul , Vaishali Thakkar , Stephen Boyd , Bjorn Andersson , Sasha Levin Subject: [PATCH 4.4 46/99] base: soc: Export soc_device_register/unregister APIs Date: Thu, 3 Oct 2019 17:53:09 +0200 Message-Id: <20191003154317.231270222@linuxfoundation.org> X-Mailer: git-send-email 2.23.0 In-Reply-To: <20191003154252.297991283@linuxfoundation.org> References: <20191003154252.297991283@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Vinod Koul [ Upstream commit f7ccc7a397cf2ef64aebb2f726970b93203858d2 ] Qcom Socinfo driver can be built as a module, so export these two APIs. Tested-by: Vinod Koul Signed-off-by: Vinod Koul Signed-off-by: Vaishali Thakkar Reviewed-by: Greg Kroah-Hartman Reviewed-by: Stephen Boyd Reviewed-by: Bjorn Andersson Signed-off-by: Bjorn Andersson Signed-off-by: Sasha Levin --- drivers/base/soc.c | 2 ++ 1 file changed, 2 insertions(+) -- 2.20.1 diff --git a/drivers/base/soc.c b/drivers/base/soc.c index 75b98aad6fafd..84242e6b2897f 100644 --- a/drivers/base/soc.c +++ b/drivers/base/soc.c @@ -146,6 +146,7 @@ struct soc_device *soc_device_register(struct soc_device_attribute *soc_dev_attr out1: return ERR_PTR(ret); } +EXPORT_SYMBOL_GPL(soc_device_register); /* Ensure soc_dev->attr is freed prior to calling soc_device_unregister. */ void soc_device_unregister(struct soc_device *soc_dev) @@ -154,6 +155,7 @@ void soc_device_unregister(struct soc_device *soc_dev) device_unregister(&soc_dev->dev); } +EXPORT_SYMBOL_GPL(soc_device_unregister); static int __init soc_bus_register(void) { From patchwork Thu Oct 3 15:53:16 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg Kroah-Hartman X-Patchwork-Id: 175087 Delivered-To: patch@linaro.org Received: by 2002:a92:7e96:0:0:0:0:0 with SMTP id q22csp511808ill; Thu, 3 Oct 2019 08:58:02 -0700 (PDT) X-Google-Smtp-Source: APXvYqxcD0d9CctArD5YU+2vkX2+vM/tBCPyPU+1D67gbRIWb4n6Zp0BLJhOQNvrrtxViu6XXUym X-Received: by 2002:a50:8ad1:: with SMTP id k17mr10370764edk.243.1570118282785; Thu, 03 Oct 2019 08:58:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570118282; cv=none; d=google.com; s=arc-20160816; b=JrIfdMbMX6YiqUhr7BFvGa6QW5LVhZobxC4UEGWxNAWrFoHaElDKx7WJrwEpwJCPWL ovbji6Vkf+HuLV2HSvFVCxN4qbwCPMBj8Ycf59zGDd/Qpmitms9/H7B0CWHYYx+qxeGs oB4+Jh2ZEjyqQtExcRzFEcRBIluzyBuVkMAZ41jNLWVTe6fSLN/cx+s5fPYDNiWf6D++ wySX9IYf1ZWq2mXiARJn20F2RbzFJl48TuO+zY8a9GWgJAW0Pmzh7RYR10zjLVoHHmjv zpEXcMz7gJN2igGHFeAG1aXXRDay/HvCGsoxtGj5NezNu2ZOgpE/YKeL8kEODJ3x05J/ gpDQ== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=wb48ma7jfGyD/ybi9x8wO3pNzI/UFdT9nC3fVpRTdcQ=; b=C6k2Umf9xh+HARaG0dkwJqyhpbItjBKis3kSBvqiKyvJN4f0SzhZFK9aAgv/K8Veuh 4yDLjCBSgM/1mchM0OEYD+90whnonO5LSgHrvYxmY0FzaZaZDFQ97B65b0bmWz1exjeX ssrDTJxofUPiUWKNQpZjh0sjUoTlW76fY7cxTHSZUB0igIl5VOA6OA6GfSaujdfdHA69 CjwTmAUHGgwb9WJ1q9qbUwOFDDNUHEzV82rkj2Xv6LQNiSGu7Zq/NAK2Xqq1vnjss9X9 o4bRgzl9F0cxs17QGks5AAUf44LFjzDB4klpsLWyx95WbeIRc+zfGNUu7e7n6XlcI8wP lqUg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=UwLZ0Bhq; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w20si1850638edc.202.2019.10.03.08.58.02; Thu, 03 Oct 2019 08:58:02 -0700 (PDT) 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=@kernel.org header.s=default header.b=UwLZ0Bhq; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731083AbfJCP6B (ORCPT + 27 others); Thu, 3 Oct 2019 11:58:01 -0400 Received: from mail.kernel.org ([198.145.29.99]:40534 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731058AbfJCP54 (ORCPT ); Thu, 3 Oct 2019 11:57:56 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id BD719207FF; Thu, 3 Oct 2019 15:57:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1570118275; bh=LBsfjmAgo2l/l1JdRmZqSp8PzoxffRVmyKd6cl3Xm1s=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=UwLZ0Bhqhr37xBw+Km5VTkNgbO3uWrU30jyT2M+mHBFqPYA4ngb4xhWC2Clg0yf5N RzU4nQQEiJhm2OB0I9H99fqHx7ooYE8uHdt4093fyO2K06vpKiMn3FWqbOyMMSDDOc rl77X7ZMnFE8pK79lwAU/ttUtm9nPZZYDTD3gkhg= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Arnd Bergmann , Vinod Koul , Sasha Levin Subject: [PATCH 4.4 53/99] dmaengine: iop-adma: use correct printk format strings Date: Thu, 3 Oct 2019 17:53:16 +0200 Message-Id: <20191003154322.154670034@linuxfoundation.org> X-Mailer: git-send-email 2.23.0 In-Reply-To: <20191003154252.297991283@linuxfoundation.org> References: <20191003154252.297991283@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Arnd Bergmann [ Upstream commit 00c9755524fbaa28117be774d7c92fddb5ca02f3 ] When compile-testing on other architectures, we get lots of warnings about incorrect format strings, like: drivers/dma/iop-adma.c: In function 'iop_adma_alloc_slots': drivers/dma/iop-adma.c:307:6: warning: format '%x' expects argument of type 'unsigned int', but argument 6 has type 'dma_addr_t {aka long long unsigned int}' [-Wformat=] drivers/dma/iop-adma.c: In function 'iop_adma_prep_dma_memcpy': >> drivers/dma/iop-adma.c:518:40: warning: format '%u' expects argument of type 'unsigned int', but argument 5 has type 'size_t {aka long unsigned int}' [-Wformat=] Use %zu for printing size_t as required, and cast the dma_addr_t arguments to 'u64' for printing with %llx. Ideally this should use the %pad format string, but that requires an lvalue argument that doesn't work here. Link: https://lore.kernel.org/r/20190809163334.489360-3-arnd@arndb.de Signed-off-by: Arnd Bergmann Acked-by: Vinod Koul Signed-off-by: Arnd Bergmann Signed-off-by: Sasha Levin --- drivers/dma/iop-adma.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) -- 2.20.1 diff --git a/drivers/dma/iop-adma.c b/drivers/dma/iop-adma.c index e4f43125e0fbb..a390415c97a86 100644 --- a/drivers/dma/iop-adma.c +++ b/drivers/dma/iop-adma.c @@ -126,9 +126,9 @@ static void __iop_adma_slot_cleanup(struct iop_adma_chan *iop_chan) list_for_each_entry_safe(iter, _iter, &iop_chan->chain, chain_node) { pr_debug("\tcookie: %d slot: %d busy: %d " - "this_desc: %#x next_desc: %#x ack: %d\n", + "this_desc: %#x next_desc: %#llx ack: %d\n", iter->async_tx.cookie, iter->idx, busy, - iter->async_tx.phys, iop_desc_get_next_desc(iter), + iter->async_tx.phys, (u64)iop_desc_get_next_desc(iter), async_tx_test_ack(&iter->async_tx)); prefetch(_iter); prefetch(&_iter->async_tx); @@ -316,9 +316,9 @@ iop_adma_alloc_slots(struct iop_adma_chan *iop_chan, int num_slots, int i; dev_dbg(iop_chan->device->common.dev, "allocated slot: %d " - "(desc %p phys: %#x) slots_per_op %d\n", + "(desc %p phys: %#llx) slots_per_op %d\n", iter->idx, iter->hw_desc, - iter->async_tx.phys, slots_per_op); + (u64)iter->async_tx.phys, slots_per_op); /* pre-ack all but the last descriptor */ if (num_slots != slots_per_op) @@ -526,7 +526,7 @@ iop_adma_prep_dma_memcpy(struct dma_chan *chan, dma_addr_t dma_dest, return NULL; BUG_ON(len > IOP_ADMA_MAX_BYTE_COUNT); - dev_dbg(iop_chan->device->common.dev, "%s len: %u\n", + dev_dbg(iop_chan->device->common.dev, "%s len: %zu\n", __func__, len); spin_lock_bh(&iop_chan->lock); @@ -559,7 +559,7 @@ iop_adma_prep_dma_xor(struct dma_chan *chan, dma_addr_t dma_dest, BUG_ON(len > IOP_ADMA_XOR_MAX_BYTE_COUNT); dev_dbg(iop_chan->device->common.dev, - "%s src_cnt: %d len: %u flags: %lx\n", + "%s src_cnt: %d len: %zu flags: %lx\n", __func__, src_cnt, len, flags); spin_lock_bh(&iop_chan->lock); @@ -592,7 +592,7 @@ iop_adma_prep_dma_xor_val(struct dma_chan *chan, dma_addr_t *dma_src, if (unlikely(!len)) return NULL; - dev_dbg(iop_chan->device->common.dev, "%s src_cnt: %d len: %u\n", + dev_dbg(iop_chan->device->common.dev, "%s src_cnt: %d len: %zu\n", __func__, src_cnt, len); spin_lock_bh(&iop_chan->lock); @@ -630,7 +630,7 @@ iop_adma_prep_dma_pq(struct dma_chan *chan, dma_addr_t *dst, dma_addr_t *src, BUG_ON(len > IOP_ADMA_XOR_MAX_BYTE_COUNT); dev_dbg(iop_chan->device->common.dev, - "%s src_cnt: %d len: %u flags: %lx\n", + "%s src_cnt: %d len: %zu flags: %lx\n", __func__, src_cnt, len, flags); if (dmaf_p_disabled_continue(flags)) @@ -693,7 +693,7 @@ iop_adma_prep_dma_pq_val(struct dma_chan *chan, dma_addr_t *pq, dma_addr_t *src, return NULL; BUG_ON(len > IOP_ADMA_XOR_MAX_BYTE_COUNT); - dev_dbg(iop_chan->device->common.dev, "%s src_cnt: %d len: %u\n", + dev_dbg(iop_chan->device->common.dev, "%s src_cnt: %d len: %zu\n", __func__, src_cnt, len); spin_lock_bh(&iop_chan->lock);