linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/7] v4.19-stable randconfig fixes
@ 2018-12-14 22:10 Arnd Bergmann
  2018-12-14 22:10 ` [PATCH 1/7] sched/pelt: Fix warning and clean up IRQ PELT config Arnd Bergmann
                   ` (7 more replies)
  0 siblings, 8 replies; 12+ messages in thread
From: Arnd Bergmann @ 2018-12-14 22:10 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: stable, Arnd Bergmann, Andrew Jeffery, Andy Gross, bp,
	Daniel Drake, David Brown, dou_liyang, Ingo Molnar,
	James E.J. Bottomley, Jens Frederich, Lubomir Rintel,
	Mark Rutland, Martin K. Petersen, Peter Zijlstra, Rob Clark,
	Rob Herring, Srinivas Kandagatla, Vincent Guittot, linux-arm-msm,
	devicetree, linux-kernel, freedreno, linux-i2c, openbmc,
	linux-arm-kernel, linux-aspeed, linux-scsi

Hi Greg,

I did some randconfig testing on linux-4.19 arm/arm64/x86. So far I needed
27 patches, most of which are also still needed in mainline Linux. I
had submitted some before, and others were not submitted previously
for some reason. I'll try to get those fixed in mainline and then
make sure we get them into 4.19 as well.

This series for now contains four patches that did make it into mainline:

2e6ae11dd0d1 ("slimbus: ngd: mark PM functions as __maybe_unused")
33f49571d750 ("staging: olpc_dcon: add a missing dependency")
0eeec01488da ("scsi: raid_attrs: fix unused variable warning")
11d4afd4ff66 ("sched/pelt: Fix warning and clean up IRQ PELT config")

Feel free to either cherry-pick those from mainline or apply the
patch from this series, whichever works best for you.

The other three patches are for warnings in code that got removed in
mainline kernels:

3e9efc3299dd ("i2c: aspeed: Handle master/slave combined irq events properly")
972910948fb6 ("ARM: dts: qcom: Remove Arrow SD600 eval board")
effec874792f ("drm/msm/dpu: Remove dpu_dbg")

My feeling was that it's safer to just address the warning by fixing
the code correctly in each of these cases, but if you disagree,
applying the mainline change should work equally well, so decide
for yourself.

      Arnd

Arnd Bergmann (5):
  scsi: raid_attrs: fix unused variable warning
  slimbus: ngd: mark PM functions as __maybe_unused
  [stable-4.19] i2c: aspeed: fix build warning
  [stable-4.19] ARM: dts: qcom-apq8064-arrow-sd-600eval fix
    graph_endpoint warning
  [stable-4.19] drm/msm:  fix address space warning

Lubomir Rintel (1):
  staging: olpc_dcon: add a missing dependency

Vincent Guittot (1):
  sched/pelt: Fix warning and clean up IRQ PELT config

 arch/arm/boot/dts/qcom-apq8064-arrow-sd-600eval.dts | 5 +++++
 drivers/gpu/drm/msm/disp/dpu1/dpu_dbg.c             | 8 ++++----
 drivers/i2c/busses/i2c-aspeed.c                     | 4 +++-
 drivers/scsi/raid_class.c                           | 4 +---
 drivers/slimbus/qcom-ngd-ctrl.c                     | 6 ++----
 drivers/staging/olpc_dcon/Kconfig                   | 1 +
 init/Kconfig                                        | 5 +++++
 kernel/sched/core.c                                 | 7 +++----
 kernel/sched/fair.c                                 | 2 +-
 kernel/sched/pelt.c                                 | 2 +-
 kernel/sched/pelt.h                                 | 2 +-
 kernel/sched/sched.h                                | 5 ++---
 12 files changed, 29 insertions(+), 22 deletions(-)

Cc: Andrew Jeffery <andrew@aj.id.au>
Cc: Andy Gross <andy.gross@linaro.org>
Cc: bp@alien8.de
Cc: Daniel Drake <dsd@laptop.org>
Cc: David Brown <david.brown@linaro.org>
Cc: dou_liyang@163.com
Cc: Ingo Molnar <mingo@redhat.com>
Cc: "James E.J. Bottomley" <jejb@linux.vnet.ibm.com>
Cc: Jens Frederich <jfrederich@gmail.com>
Cc: Lubomir Rintel <lkundrak@v3.sk>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: "Martin K. Petersen" <martin.petersen@oracle.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Rob Clark <robdclark@gmail.com>
Cc: Rob Herring <robh+dt@kernel.org>
Cc: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Cc: Vincent Guittot <vincent.guittot@linaro.org>
Cc: linux-arm-msm@vger.kernel.org
Cc: devicetree@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Cc: freedreno@lists.freedesktop.org
Cc: linux-i2c@vger.kernel.org
Cc: openbmc@lists.ozlabs.org
Cc: linux-arm-kernel@lists.infradead.org
Cc: linux-aspeed@lists.ozlabs.org
Cc: linux-scsi@vger.kernel.org


-- 
2.20.0


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [PATCH 1/7] sched/pelt: Fix warning and clean up IRQ PELT config
  2018-12-14 22:10 [PATCH 0/7] v4.19-stable randconfig fixes Arnd Bergmann
@ 2018-12-14 22:10 ` Arnd Bergmann
  2018-12-14 22:10 ` [PATCH 2/7] scsi: raid_attrs: fix unused variable warning Arnd Bergmann
                   ` (6 subsequent siblings)
  7 siblings, 0 replies; 12+ messages in thread
From: Arnd Bergmann @ 2018-12-14 22:10 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Ingo Molnar, Peter Zijlstra
  Cc: stable, Vincent Guittot, Dou Liyang, Miguel Ojeda,
	Linus Torvalds, Thomas Gleixner, bp, dou_liyang, Ingo Molnar,
	linux-kernel

From: Vincent Guittot <vincent.guittot@linaro.org>

Commit 11d4afd4ff667f9b6178ee8c142c36cb78bd84db upstream.

Create a config for enabling irq load tracking in the scheduler.
irq load tracking is useful only when irq or paravirtual time is
accounted but it's only possible with SMP for now.

Also use __maybe_unused to remove the compilation warning in
update_rq_clock_task() that has been introduced by:

  2e62c4743adc ("sched/fair: Remove #ifdefs from scale_rt_capacity()")

Suggested-by: Ingo Molnar <mingo@redhat.com>
Reported-by: Dou Liyang <douly.fnst@cn.fujitsu.com>
Reported-by: Miguel Ojeda <miguel.ojeda.sandonis@gmail.com>
Signed-off-by: Vincent Guittot <vincent.guittot@linaro.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: bp@alien8.de
Cc: dou_liyang@163.com
Fixes: 2e62c4743adc ("sched/fair: Remove #ifdefs from scale_rt_capacity()")
Link: http://lkml.kernel.org/r/1537867062-27285-1-git-send-email-vincent.guittot@linaro.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
---
 init/Kconfig         | 5 +++++
 kernel/sched/core.c  | 7 +++----
 kernel/sched/fair.c  | 2 +-
 kernel/sched/pelt.c  | 2 +-
 kernel/sched/pelt.h  | 2 +-
 kernel/sched/sched.h | 5 ++---
 6 files changed, 13 insertions(+), 10 deletions(-)

diff --git a/init/Kconfig b/init/Kconfig
index 1e234e2f1cba..317d5ccb5191 100644
--- a/init/Kconfig
+++ b/init/Kconfig
@@ -415,6 +415,11 @@ config IRQ_TIME_ACCOUNTING
 
 	  If in doubt, say N here.
 
+config HAVE_SCHED_AVG_IRQ
+	def_bool y
+	depends on IRQ_TIME_ACCOUNTING || PARAVIRT_TIME_ACCOUNTING
+	depends on SMP
+
 config BSD_PROCESS_ACCT
 	bool "BSD Process Accounting"
 	depends on MULTIUSER
diff --git a/kernel/sched/core.c b/kernel/sched/core.c
index 2beda4b726e2..13ddfa46d741 100644
--- a/kernel/sched/core.c
+++ b/kernel/sched/core.c
@@ -135,9 +135,8 @@ static void update_rq_clock_task(struct rq *rq, s64 delta)
  * In theory, the compile should just see 0 here, and optimize out the call
  * to sched_rt_avg_update. But I don't trust it...
  */
-#if defined(CONFIG_IRQ_TIME_ACCOUNTING) || defined(CONFIG_PARAVIRT_TIME_ACCOUNTING)
-	s64 steal = 0, irq_delta = 0;
-#endif
+	s64 __maybe_unused steal = 0, irq_delta = 0;
+
 #ifdef CONFIG_IRQ_TIME_ACCOUNTING
 	irq_delta = irq_time_read(cpu_of(rq)) - rq->prev_irq_time;
 
@@ -177,7 +176,7 @@ static void update_rq_clock_task(struct rq *rq, s64 delta)
 
 	rq->clock_task += delta;
 
-#ifdef HAVE_SCHED_AVG_IRQ
+#ifdef CONFIG_HAVE_SCHED_AVG_IRQ
 	if ((irq_delta + steal) && sched_feat(NONTASK_CAPACITY))
 		update_irq_load_avg(rq, irq_delta + steal);
 #endif
diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
index 1162552dc3cc..eabbf6b10b44 100644
--- a/kernel/sched/fair.c
+++ b/kernel/sched/fair.c
@@ -7361,7 +7361,7 @@ static inline bool others_have_blocked(struct rq *rq)
 	if (READ_ONCE(rq->avg_dl.util_avg))
 		return true;
 
-#if defined(CONFIG_IRQ_TIME_ACCOUNTING) || defined(CONFIG_PARAVIRT_TIME_ACCOUNTING)
+#ifdef CONFIG_HAVE_SCHED_AVG_IRQ
 	if (READ_ONCE(rq->avg_irq.util_avg))
 		return true;
 #endif
diff --git a/kernel/sched/pelt.c b/kernel/sched/pelt.c
index 35475c0c5419..48a126486435 100644
--- a/kernel/sched/pelt.c
+++ b/kernel/sched/pelt.c
@@ -358,7 +358,7 @@ int update_dl_rq_load_avg(u64 now, struct rq *rq, int running)
 	return 0;
 }
 
-#if defined(CONFIG_IRQ_TIME_ACCOUNTING) || defined(CONFIG_PARAVIRT_TIME_ACCOUNTING)
+#ifdef CONFIG_HAVE_SCHED_AVG_IRQ
 /*
  * irq:
  *
diff --git a/kernel/sched/pelt.h b/kernel/sched/pelt.h
index d2894db28955..7e56b489ff32 100644
--- a/kernel/sched/pelt.h
+++ b/kernel/sched/pelt.h
@@ -6,7 +6,7 @@ int __update_load_avg_cfs_rq(u64 now, int cpu, struct cfs_rq *cfs_rq);
 int update_rt_rq_load_avg(u64 now, struct rq *rq, int running);
 int update_dl_rq_load_avg(u64 now, struct rq *rq, int running);
 
-#if defined(CONFIG_IRQ_TIME_ACCOUNTING) || defined(CONFIG_PARAVIRT_TIME_ACCOUNTING)
+#ifdef CONFIG_HAVE_SCHED_AVG_IRQ
 int update_irq_load_avg(struct rq *rq, u64 running);
 #else
 static inline int
diff --git a/kernel/sched/sched.h b/kernel/sched/sched.h
index 6c25bbe87bd3..b63172288f7b 100644
--- a/kernel/sched/sched.h
+++ b/kernel/sched/sched.h
@@ -859,8 +859,7 @@ struct rq {
 
 	struct sched_avg	avg_rt;
 	struct sched_avg	avg_dl;
-#if defined(CONFIG_IRQ_TIME_ACCOUNTING) || defined(CONFIG_PARAVIRT_TIME_ACCOUNTING)
-#define HAVE_SCHED_AVG_IRQ
+#ifdef CONFIG_HAVE_SCHED_AVG_IRQ
 	struct sched_avg	avg_irq;
 #endif
 	u64			idle_stamp;
@@ -2215,7 +2214,7 @@ static inline unsigned long cpu_util_rt(struct rq *rq)
 }
 #endif
 
-#ifdef HAVE_SCHED_AVG_IRQ
+#ifdef CONFIG_HAVE_SCHED_AVG_IRQ
 static inline unsigned long cpu_util_irq(struct rq *rq)
 {
 	return rq->avg_irq.util_avg;
-- 
2.20.0


^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH 2/7] scsi: raid_attrs: fix unused variable warning
  2018-12-14 22:10 [PATCH 0/7] v4.19-stable randconfig fixes Arnd Bergmann
  2018-12-14 22:10 ` [PATCH 1/7] sched/pelt: Fix warning and clean up IRQ PELT config Arnd Bergmann
@ 2018-12-14 22:10 ` Arnd Bergmann
  2018-12-14 22:10 ` [PATCH 3/7] staging: olpc_dcon: add a missing dependency Arnd Bergmann
                   ` (5 subsequent siblings)
  7 siblings, 0 replies; 12+ messages in thread
From: Arnd Bergmann @ 2018-12-14 22:10 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: stable, Arnd Bergmann, Martin K . Petersen, James E.J. Bottomley,
	linux-scsi, linux-kernel

Commit 0eeec01488da9b1403c8c29e73eacac8af9e4bf2 upstream.

I ran into a new warning on randconfig kernels:

drivers/scsi/raid_class.c: In function 'raid_match':
drivers/scsi/raid_class.c:64:24: error: unused variable 'i' [-Werror=unused-variable]

This looks like a very old problem that for some reason was very hard to
run into, but it is very easy to fix, by replacing the incorrect #ifdef
with a simpler IS_ENABLED() check.

Fixes: fac829fdcaf4 ("[SCSI] raid_attrs: fix dependency problems")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
---
 drivers/scsi/raid_class.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/scsi/raid_class.c b/drivers/scsi/raid_class.c
index ea88906d2cc5..5c3d6e1e0145 100644
--- a/drivers/scsi/raid_class.c
+++ b/drivers/scsi/raid_class.c
@@ -63,8 +63,7 @@ static int raid_match(struct attribute_container *cont, struct device *dev)
 	 * emulated RAID devices, so start with SCSI */
 	struct raid_internal *i = ac_to_raid_internal(cont);
 
-#if defined(CONFIG_SCSI) || defined(CONFIG_SCSI_MODULE)
-	if (scsi_is_sdev_device(dev)) {
+	if (IS_ENABLED(CONFIG_SCSI) && scsi_is_sdev_device(dev)) {
 		struct scsi_device *sdev = to_scsi_device(dev);
 
 		if (i->f->cookie != sdev->host->hostt)
@@ -72,7 +71,6 @@ static int raid_match(struct attribute_container *cont, struct device *dev)
 
 		return i->f->is_raid(dev);
 	}
-#endif
 	/* FIXME: look at other subsystems too */
 	return 0;
 }
-- 
2.20.0


^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH 3/7] staging: olpc_dcon: add a missing dependency
  2018-12-14 22:10 [PATCH 0/7] v4.19-stable randconfig fixes Arnd Bergmann
  2018-12-14 22:10 ` [PATCH 1/7] sched/pelt: Fix warning and clean up IRQ PELT config Arnd Bergmann
  2018-12-14 22:10 ` [PATCH 2/7] scsi: raid_attrs: fix unused variable warning Arnd Bergmann
@ 2018-12-14 22:10 ` Arnd Bergmann
  2018-12-14 22:10 ` [PATCH 4/7] slimbus: ngd: mark PM functions as __maybe_unused Arnd Bergmann
                   ` (4 subsequent siblings)
  7 siblings, 0 replies; 12+ messages in thread
From: Arnd Bergmann @ 2018-12-14 22:10 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Jens Frederich, Daniel Drake
  Cc: stable, Lubomir Rintel, Arnd Bergmann, devel, linux-kernel

From: Lubomir Rintel <lkundrak@v3.sk>

Commit 33f49571d75024b1044cd02689ad2bdb4924cc80 upstream.

  WARNING: unmet direct dependencies detected for BACKLIGHT_CLASS_DEVICE
    Depends on [n]: HAS_IOMEM [=y] && BACKLIGHT_LCD_SUPPORT [=n]
    Selected by [y]:
    - FB_OLPC_DCON [=y] && STAGING [=y] && X86 [=y] && OLPC [=y] && FB [=y]
                        && I2C [=y] && (GPIO_CS5535 [=n] || GPIO_CS5535 [=n]=n)

Signed-off-by: Lubomir Rintel <lkundrak@v3.sk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
 drivers/staging/olpc_dcon/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/staging/olpc_dcon/Kconfig b/drivers/staging/olpc_dcon/Kconfig
index c91a56f77bcb..192cc8d0853f 100644
--- a/drivers/staging/olpc_dcon/Kconfig
+++ b/drivers/staging/olpc_dcon/Kconfig
@@ -2,6 +2,7 @@ config FB_OLPC_DCON
 	tristate "One Laptop Per Child Display CONtroller support"
 	depends on OLPC && FB
 	depends on I2C
+	depends on BACKLIGHT_LCD_SUPPORT
 	depends on (GPIO_CS5535 || GPIO_CS5535=n)
 	select BACKLIGHT_CLASS_DEVICE
 	help
-- 
2.20.0


^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH 4/7] slimbus: ngd: mark PM functions as __maybe_unused
  2018-12-14 22:10 [PATCH 0/7] v4.19-stable randconfig fixes Arnd Bergmann
                   ` (2 preceding siblings ...)
  2018-12-14 22:10 ` [PATCH 3/7] staging: olpc_dcon: add a missing dependency Arnd Bergmann
@ 2018-12-14 22:10 ` Arnd Bergmann
  2018-12-14 22:10 ` [PATCH 5/7] [stable-4.19] i2c: aspeed: fix build warning Arnd Bergmann
                   ` (3 subsequent siblings)
  7 siblings, 0 replies; 12+ messages in thread
From: Arnd Bergmann @ 2018-12-14 22:10 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Srinivas Kandagatla
  Cc: stable, Arnd Bergmann, alsa-devel, linux-kernel

Commit 2e6ae11dd0d1c37f44cec51a58fb2092e55ed0f5 upstream.

qcom_slim_ngd_runtime_suspend is protected by an #ifdef,
qcom_slim_ngd_runtime_idle is now, which causes a build time warning:

drivers/slimbus/qcom-ngd-ctrl.c:1470:12: error: 'qcom_slim_ngd_runtime_idle' defined but not used [-Werror=unused-function]

Marking both as __maybe_unused lets us get rid of the warning
as well as the #ifdef.

Fixes: 917809e2280b ("slimbus: ngd: Add qcom SLIMBus NGD driver")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
 drivers/slimbus/qcom-ngd-ctrl.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/slimbus/qcom-ngd-ctrl.c b/drivers/slimbus/qcom-ngd-ctrl.c
index 8be4d6786c61..14a9d18306cb 100644
--- a/drivers/slimbus/qcom-ngd-ctrl.c
+++ b/drivers/slimbus/qcom-ngd-ctrl.c
@@ -1467,7 +1467,7 @@ static int qcom_slim_ngd_remove(struct platform_device *pdev)
 	return 0;
 }
 
-static int qcom_slim_ngd_runtime_idle(struct device *dev)
+static int __maybe_unused qcom_slim_ngd_runtime_idle(struct device *dev)
 {
 	struct qcom_slim_ngd_ctrl *ctrl = dev_get_drvdata(dev);
 
@@ -1477,8 +1477,7 @@ static int qcom_slim_ngd_runtime_idle(struct device *dev)
 	return -EAGAIN;
 }
 
-#ifdef CONFIG_PM
-static int qcom_slim_ngd_runtime_suspend(struct device *dev)
+static int __maybe_unused qcom_slim_ngd_runtime_suspend(struct device *dev)
 {
 	struct qcom_slim_ngd_ctrl *ctrl = dev_get_drvdata(dev);
 	int ret = 0;
@@ -1491,7 +1490,6 @@ static int qcom_slim_ngd_runtime_suspend(struct device *dev)
 
 	return ret;
 }
-#endif
 
 static const struct dev_pm_ops qcom_slim_ngd_dev_pm_ops = {
 	SET_SYSTEM_SLEEP_PM_OPS(pm_runtime_force_suspend,
-- 
2.20.0


^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH 5/7] [stable-4.19] i2c: aspeed: fix build warning
  2018-12-14 22:10 [PATCH 0/7] v4.19-stable randconfig fixes Arnd Bergmann
                   ` (3 preceding siblings ...)
  2018-12-14 22:10 ` [PATCH 4/7] slimbus: ngd: mark PM functions as __maybe_unused Arnd Bergmann
@ 2018-12-14 22:10 ` Arnd Bergmann
  2018-12-14 23:30   ` Brendan Higgins
  2018-12-14 22:10 ` [PATCH 6/7] [stable-4.19] ARM: dts: qcom-apq8064-arrow-sd-600eval fix graph_endpoint warning Arnd Bergmann
                   ` (2 subsequent siblings)
  7 siblings, 1 reply; 12+ messages in thread
From: Arnd Bergmann @ 2018-12-14 22:10 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Brendan Higgins, Joel Stanley
  Cc: stable, Arnd Bergmann, openbmc, linux-aspeed, linux-kernel

Upstream commit 3e9efc3299dd ("i2c: aspeed: Handle master/slave combined irq events
properly") reworked the interrupt handling and fixed a warning in the process:

drivers/i2c/busses/i2c-aspeed.c: In function 'aspeed_i2c_bus_irq':
drivers/i2c/busses/i2c-aspeed.c:567:1: error: label 'out' defined but not used [-Werror=unused-label]

The warning is still present in v4.19.8 and can be fixed either by applying
that original patch, or by adding a simple #ifdef.

Here, I choose the second simpler option as the original patch seems too
invasive for a stable backport.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/i2c/busses/i2c-aspeed.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/i2c/busses/i2c-aspeed.c b/drivers/i2c/busses/i2c-aspeed.c
index a4f956c6d567..a19fbff16861 100644
--- a/drivers/i2c/busses/i2c-aspeed.c
+++ b/drivers/i2c/busses/i2c-aspeed.c
@@ -555,7 +555,7 @@ static irqreturn_t aspeed_i2c_bus_irq(int irq, void *dev_id)
 	spin_lock(&bus->lock);
 
 #if IS_ENABLED(CONFIG_I2C_SLAVE)
-	if (aspeed_i2c_slave_irq(bus)) {
+	if (IS_ENABLED(CONFIG_I2C_SLAVE) && aspeed_i2c_slave_irq(bus)) {
 		dev_dbg(bus->dev, "irq handled by slave.\n");
 		ret = true;
 		goto out;
@@ -564,7 +564,9 @@ static irqreturn_t aspeed_i2c_bus_irq(int irq, void *dev_id)
 
 	ret = aspeed_i2c_master_irq(bus);
 
+#if IS_ENABLED(CONFIG_I2C_SLAVE)
 out:
+#endif
 	spin_unlock(&bus->lock);
 	return ret ? IRQ_HANDLED : IRQ_NONE;
 }
-- 
2.20.0


^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH 6/7] [stable-4.19] ARM: dts: qcom-apq8064-arrow-sd-600eval fix graph_endpoint warning
  2018-12-14 22:10 [PATCH 0/7] v4.19-stable randconfig fixes Arnd Bergmann
                   ` (4 preceding siblings ...)
  2018-12-14 22:10 ` [PATCH 5/7] [stable-4.19] i2c: aspeed: fix build warning Arnd Bergmann
@ 2018-12-14 22:10 ` Arnd Bergmann
  2018-12-14 22:10 ` [PATCH 7/7] [stable-4.19] drm/msm: fix address space warning Arnd Bergmann
  2018-12-18  0:20 ` [PATCH 0/7] v4.19-stable randconfig fixes Sasha Levin
  7 siblings, 0 replies; 12+ messages in thread
From: Arnd Bergmann @ 2018-12-14 22:10 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: stable, Arnd Bergmann, Andy Gross, Rob Herring, devicetree, linux-kernel

Upstream commit 972910948fb6 ("ARM: dts: qcom: Remove Arrow SD600
eval board") removed this file because there are no known users,
but in linux-4.19.y, we still get a compile-time warnign for it:

arch/arm/boot/dts/qcom-apq8064-arrow-sd-600eval.dtb: Warning (graph_endpoint): /soc/mdp@5100000/ports/port@3/endpoint: graph connection to node '/soc/hdmi-tx@4a00000/ports/port@0/endpoint' is not bidirectional

Address the warning by adding the remote endpoint that makes the link
bidirectional. This is the same property that other boards use.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 arch/arm/boot/dts/qcom-apq8064-arrow-sd-600eval.dts | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/arch/arm/boot/dts/qcom-apq8064-arrow-sd-600eval.dts b/arch/arm/boot/dts/qcom-apq8064-arrow-sd-600eval.dts
index 76b56eafaab9..f714a20649d7 100644
--- a/arch/arm/boot/dts/qcom-apq8064-arrow-sd-600eval.dts
+++ b/arch/arm/boot/dts/qcom-apq8064-arrow-sd-600eval.dts
@@ -387,6 +387,11 @@
 			hpd-gpio = <&tlmm_pinmux 72 GPIO_ACTIVE_HIGH>;
 
 			ports {
+				port@0 {
+					endpoint {
+						remote-endpoint = <&mdp_dtv_out>;
+					};
+				};
 				port@1 {
 					endpoint {
 						remote-endpoint = <&hdmi_con>;
-- 
2.20.0


^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [PATCH 7/7] [stable-4.19] drm/msm:  fix address space warning
  2018-12-14 22:10 [PATCH 0/7] v4.19-stable randconfig fixes Arnd Bergmann
                   ` (5 preceding siblings ...)
  2018-12-14 22:10 ` [PATCH 6/7] [stable-4.19] ARM: dts: qcom-apq8064-arrow-sd-600eval fix graph_endpoint warning Arnd Bergmann
@ 2018-12-14 22:10 ` Arnd Bergmann
  2018-12-18  0:20 ` [PATCH 0/7] v4.19-stable randconfig fixes Sasha Levin
  7 siblings, 0 replies; 12+ messages in thread
From: Arnd Bergmann @ 2018-12-14 22:10 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: stable, Arnd Bergmann, Rob Clark, freedreno, linux-kernel

In the linux-4.19 stable kernel, we get a warning about a type
mismatch between phys_addr_t and dma_addr_t:

drivers/gpu/drm/msm/disp/dpu1/dpu_dbg.c: In function '_dpu_dbg_dump_dpu_dbg_bus':
drivers/gpu/drm/msm/disp/dpu1/dpu_dbg.c:2003:16: error: passing argument 3 of 'dma_alloc_coherent' from incompatible pointer type [-Werror=incompatible-pointer-types]
     list_size, &phys, GFP_KERNEL);
                ^~~~~
In file included from include/linux/dma-buf.h:31,
                 from drivers/gpu/drm/msm/disp/dpu1/dpu_dbg.c:20:
include/linux/dma-mapping.h:561:15: note: expected 'dma_addr_t *' {aka 'long long unsigned int *'} but argument is of type 'phys_addr_t *' {aka 'unsigned int *'}
   dma_addr_t *dma_handle, gfp_t flag)
   ~~~~~~~~~~~~^~~~~~~~~~
drivers/gpu/drm/msm/disp/dpu1/dpu_dbg.c: In function '_dpu_dbg_dump_vbif_dbg_bus':
drivers/gpu/drm/msm/disp/dpu1/dpu_dbg.c:2154:16: error: passing argument 3 of 'dma_alloc_coherent' from incompatible pointer type [-Werror=incompatible-pointer-types]
     list_size, &phys, GFP_KERNEL);
                ^~~~~
In file included from include/linux/dma-buf.h:31,
                 from drivers/gpu/drm/msm/disp/dpu1/dpu_dbg.c:20:
include/linux/dma-mapping.h:561:15: note: expected 'dma_addr_t *' {aka 'long long unsigned int *'} but argument is of type 'phys_addr_t *' {aka 'unsigned int *'}

This code was removed in linux-4.20 with upstream commit effec874792f
("drm/msm/dpu: Remove dpu_dbg"). Rather than backporting the large
patch, this just fixes the warning by using the correct type.

Fixes: 25fdd5933e4c ("drm/msm: Add SDM845 DPU support")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/gpu/drm/msm/disp/dpu1/dpu_dbg.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_dbg.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_dbg.c
index ae2aee7ed9e1..e741d26185df 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_dbg.c
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_dbg.c
@@ -1962,7 +1962,7 @@ static void _dpu_dbg_dump_dpu_dbg_bus(struct dpu_dbg_dpu_debug_bus *bus)
 	u32 *dump_addr = NULL;
 	u32 status = 0;
 	struct dpu_debug_bus_entry *head;
-	phys_addr_t phys = 0;
+	dma_addr_t dma = 0;
 	int list_size;
 	int i;
 	u32 offset;
@@ -2000,7 +2000,7 @@ static void _dpu_dbg_dump_dpu_dbg_bus(struct dpu_dbg_dpu_debug_bus *bus)
 	if (in_mem) {
 		if (!(*dump_mem))
 			*dump_mem = dma_alloc_coherent(dpu_dbg_base.dev,
-				list_size, &phys, GFP_KERNEL);
+				list_size, &dma, GFP_KERNEL);
 
 		if (*dump_mem) {
 			dump_addr = *dump_mem;
@@ -2101,7 +2101,7 @@ static void _dpu_dbg_dump_vbif_dbg_bus(struct dpu_dbg_vbif_debug_bus *bus)
 	u32 value, d0, d1;
 	unsigned long reg, reg1, reg2;
 	struct vbif_debug_bus_entry *head;
-	phys_addr_t phys = 0;
+	dma_addr_t dma = 0;
 	int i, list_size = 0;
 	void __iomem *mem_base = NULL;
 	struct vbif_debug_bus_entry *dbg_bus;
@@ -2151,7 +2151,7 @@ static void _dpu_dbg_dump_vbif_dbg_bus(struct dpu_dbg_vbif_debug_bus *bus)
 	if (in_mem) {
 		if (!(*dump_mem))
 			*dump_mem = dma_alloc_coherent(dpu_dbg_base.dev,
-				list_size, &phys, GFP_KERNEL);
+				list_size, &dma, GFP_KERNEL);
 
 		if (*dump_mem) {
 			dump_addr = *dump_mem;
-- 
2.20.0


^ permalink raw reply related	[flat|nested] 12+ messages in thread

* Re: [PATCH 5/7] [stable-4.19] i2c: aspeed: fix build warning
  2018-12-14 22:10 ` [PATCH 5/7] [stable-4.19] i2c: aspeed: fix build warning Arnd Bergmann
@ 2018-12-14 23:30   ` Brendan Higgins
  0 siblings, 0 replies; 12+ messages in thread
From: Brendan Higgins @ 2018-12-14 23:30 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Greg KH, Joel Stanley, stable, OpenBMC Maillist, linux-aspeed,
	Linux Kernel Mailing List

On Fri, Dec 14, 2018 at 2:12 PM Arnd Bergmann <arnd@arndb.de> wrote:
>
> Upstream commit 3e9efc3299dd ("i2c: aspeed: Handle master/slave combined irq events
> properly") reworked the interrupt handling and fixed a warning in the process:
>
> drivers/i2c/busses/i2c-aspeed.c: In function 'aspeed_i2c_bus_irq':
> drivers/i2c/busses/i2c-aspeed.c:567:1: error: label 'out' defined but not used [-Werror=unused-label]
>
> The warning is still present in v4.19.8 and can be fixed either by applying
> that original patch, or by adding a simple #ifdef.
>
> Here, I choose the second simpler option as the original patch seems too
> invasive for a stable backport.
>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>

Thanks!

Reviewed-by: Brendan Higgins <brendanhiggins@google.com>

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH 0/7] v4.19-stable randconfig fixes
  2018-12-14 22:10 [PATCH 0/7] v4.19-stable randconfig fixes Arnd Bergmann
                   ` (6 preceding siblings ...)
  2018-12-14 22:10 ` [PATCH 7/7] [stable-4.19] drm/msm: fix address space warning Arnd Bergmann
@ 2018-12-18  0:20 ` Sasha Levin
  2018-12-18 15:12   ` Greg Kroah-Hartman
  7 siblings, 1 reply; 12+ messages in thread
From: Sasha Levin @ 2018-12-18  0:20 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Greg Kroah-Hartman, stable, Andrew Jeffery, Andy Gross, bp,
	Daniel Drake, David Brown, dou_liyang, Ingo Molnar,
	James E.J. Bottomley, Jens Frederich, Lubomir Rintel,
	Mark Rutland, Martin K. Petersen, Peter Zijlstra, Rob Clark,
	Rob Herring, Srinivas Kandagatla, Vincent Guittot, linux-arm-msm,
	devicetree, linux-kernel, freedreno, linux-i2c, openbmc,
	linux-arm-kernel, linux-aspeed, linux-scsi

On Fri, Dec 14, 2018 at 11:10:05PM +0100, Arnd Bergmann wrote:
>Hi Greg,
>
>I did some randconfig testing on linux-4.19 arm/arm64/x86. So far I needed
>27 patches, most of which are also still needed in mainline Linux. I
>had submitted some before, and others were not submitted previously
>for some reason. I'll try to get those fixed in mainline and then
>make sure we get them into 4.19 as well.
>
>This series for now contains four patches that did make it into mainline:
>
>2e6ae11dd0d1 ("slimbus: ngd: mark PM functions as __maybe_unused")
>33f49571d750 ("staging: olpc_dcon: add a missing dependency")
>0eeec01488da ("scsi: raid_attrs: fix unused variable warning")
>11d4afd4ff66 ("sched/pelt: Fix warning and clean up IRQ PELT config")
>
>Feel free to either cherry-pick those from mainline or apply the
>patch from this series, whichever works best for you.
>
>The other three patches are for warnings in code that got removed in
>mainline kernels:
>
>3e9efc3299dd ("i2c: aspeed: Handle master/slave combined irq events properly")
>972910948fb6 ("ARM: dts: qcom: Remove Arrow SD600 eval board")
>effec874792f ("drm/msm/dpu: Remove dpu_dbg")
>
>My feeling was that it's safer to just address the warning by fixing
>the code correctly in each of these cases, but if you disagree,
>applying the mainline change should work equally well, so decide
>for yourself.

Thanks Arnd, I took the series as is.

We really need to discuss how -stable deals with removed code upstream.
For some cases, we should probably follow suit and remove it from
-stable as well (I'm mostly thinking dodgy code with potential security
issues).

--
Thanks,
Sasha

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH 0/7] v4.19-stable randconfig fixes
  2018-12-18  0:20 ` [PATCH 0/7] v4.19-stable randconfig fixes Sasha Levin
@ 2018-12-18 15:12   ` Greg Kroah-Hartman
  2018-12-18 16:20     ` Sasha Levin
  0 siblings, 1 reply; 12+ messages in thread
From: Greg Kroah-Hartman @ 2018-12-18 15:12 UTC (permalink / raw)
  To: Sasha Levin
  Cc: Arnd Bergmann, stable, Andrew Jeffery, Andy Gross, bp,
	Daniel Drake, David Brown, dou_liyang, Ingo Molnar,
	James E.J. Bottomley, Jens Frederich, Lubomir Rintel,
	Mark Rutland, Martin K. Petersen, Peter Zijlstra, Rob Clark,
	Rob Herring, Srinivas Kandagatla, Vincent Guittot, linux-arm-msm,
	devicetree, linux-kernel, freedreno, linux-i2c, openbmc,
	linux-arm-kernel, linux-aspeed, linux-scsi

On Mon, Dec 17, 2018 at 07:20:28PM -0500, Sasha Levin wrote:
> On Fri, Dec 14, 2018 at 11:10:05PM +0100, Arnd Bergmann wrote:
> > Hi Greg,
> > 
> > I did some randconfig testing on linux-4.19 arm/arm64/x86. So far I needed
> > 27 patches, most of which are also still needed in mainline Linux. I
> > had submitted some before, and others were not submitted previously
> > for some reason. I'll try to get those fixed in mainline and then
> > make sure we get them into 4.19 as well.
> > 
> > This series for now contains four patches that did make it into mainline:
> > 
> > 2e6ae11dd0d1 ("slimbus: ngd: mark PM functions as __maybe_unused")
> > 33f49571d750 ("staging: olpc_dcon: add a missing dependency")
> > 0eeec01488da ("scsi: raid_attrs: fix unused variable warning")
> > 11d4afd4ff66 ("sched/pelt: Fix warning and clean up IRQ PELT config")
> > 
> > Feel free to either cherry-pick those from mainline or apply the
> > patch from this series, whichever works best for you.
> > 
> > The other three patches are for warnings in code that got removed in
> > mainline kernels:
> > 
> > 3e9efc3299dd ("i2c: aspeed: Handle master/slave combined irq events properly")
> > 972910948fb6 ("ARM: dts: qcom: Remove Arrow SD600 eval board")
> > effec874792f ("drm/msm/dpu: Remove dpu_dbg")
> > 
> > My feeling was that it's safer to just address the warning by fixing
> > the code correctly in each of these cases, but if you disagree,
> > applying the mainline change should work equally well, so decide
> > for yourself.
> 
> Thanks Arnd, I took the series as is.
> 
> We really need to discuss how -stable deals with removed code upstream.
> For some cases, we should probably follow suit and remove it from
> -stable as well (I'm mostly thinking dodgy code with potential security
> issues).

It would be nice to do that at times (like lustre and ipx), but it's
good to keep that code around as maybe someone is using it?  I don't
know, it's a tough call...

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [PATCH 0/7] v4.19-stable randconfig fixes
  2018-12-18 15:12   ` Greg Kroah-Hartman
@ 2018-12-18 16:20     ` Sasha Levin
  0 siblings, 0 replies; 12+ messages in thread
From: Sasha Levin @ 2018-12-18 16:20 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: Arnd Bergmann, stable, Andrew Jeffery, Andy Gross, bp,
	Daniel Drake, David Brown, dou_liyang, Ingo Molnar,
	James E.J. Bottomley, Jens Frederich, Lubomir Rintel,
	Mark Rutland, Martin K. Petersen, Peter Zijlstra, Rob Clark,
	Rob Herring, Srinivas Kandagatla, Vincent Guittot, linux-arm-msm,
	devicetree, linux-kernel, freedreno, linux-i2c, openbmc,
	linux-arm-kernel, linux-aspeed, linux-scsi

On Tue, Dec 18, 2018 at 04:12:30PM +0100, Greg Kroah-Hartman wrote:
>On Mon, Dec 17, 2018 at 07:20:28PM -0500, Sasha Levin wrote:
>> On Fri, Dec 14, 2018 at 11:10:05PM +0100, Arnd Bergmann wrote:
>> > Hi Greg,
>> >
>> > I did some randconfig testing on linux-4.19 arm/arm64/x86. So far I needed
>> > 27 patches, most of which are also still needed in mainline Linux. I
>> > had submitted some before, and others were not submitted previously
>> > for some reason. I'll try to get those fixed in mainline and then
>> > make sure we get them into 4.19 as well.
>> >
>> > This series for now contains four patches that did make it into mainline:
>> >
>> > 2e6ae11dd0d1 ("slimbus: ngd: mark PM functions as __maybe_unused")
>> > 33f49571d750 ("staging: olpc_dcon: add a missing dependency")
>> > 0eeec01488da ("scsi: raid_attrs: fix unused variable warning")
>> > 11d4afd4ff66 ("sched/pelt: Fix warning and clean up IRQ PELT config")
>> >
>> > Feel free to either cherry-pick those from mainline or apply the
>> > patch from this series, whichever works best for you.
>> >
>> > The other three patches are for warnings in code that got removed in
>> > mainline kernels:
>> >
>> > 3e9efc3299dd ("i2c: aspeed: Handle master/slave combined irq events properly")
>> > 972910948fb6 ("ARM: dts: qcom: Remove Arrow SD600 eval board")
>> > effec874792f ("drm/msm/dpu: Remove dpu_dbg")
>> >
>> > My feeling was that it's safer to just address the warning by fixing
>> > the code correctly in each of these cases, but if you disagree,
>> > applying the mainline change should work equally well, so decide
>> > for yourself.
>>
>> Thanks Arnd, I took the series as is.
>>
>> We really need to discuss how -stable deals with removed code upstream.
>> For some cases, we should probably follow suit and remove it from
>> -stable as well (I'm mostly thinking dodgy code with potential security
>> issues).
>
>It would be nice to do that at times (like lustre and ipx), but it's
>good to keep that code around as maybe someone is using it?  I don't
>know, it's a tough call...

Yeah, it's really a case-by-case basis. I'm really concerned about an
unmaintained piece of code in stable kernels, no one actually fixes bug
in it.

With the example here where that eval board was removed because no one
was using it is a great example of code we should be removing from
stable trees as well. If no one is using it - great! but if someone
does, then the removal should be reverted upstream as well.

--
Thanks,
Sasha

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2018-12-18 16:20 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-12-14 22:10 [PATCH 0/7] v4.19-stable randconfig fixes Arnd Bergmann
2018-12-14 22:10 ` [PATCH 1/7] sched/pelt: Fix warning and clean up IRQ PELT config Arnd Bergmann
2018-12-14 22:10 ` [PATCH 2/7] scsi: raid_attrs: fix unused variable warning Arnd Bergmann
2018-12-14 22:10 ` [PATCH 3/7] staging: olpc_dcon: add a missing dependency Arnd Bergmann
2018-12-14 22:10 ` [PATCH 4/7] slimbus: ngd: mark PM functions as __maybe_unused Arnd Bergmann
2018-12-14 22:10 ` [PATCH 5/7] [stable-4.19] i2c: aspeed: fix build warning Arnd Bergmann
2018-12-14 23:30   ` Brendan Higgins
2018-12-14 22:10 ` [PATCH 6/7] [stable-4.19] ARM: dts: qcom-apq8064-arrow-sd-600eval fix graph_endpoint warning Arnd Bergmann
2018-12-14 22:10 ` [PATCH 7/7] [stable-4.19] drm/msm: fix address space warning Arnd Bergmann
2018-12-18  0:20 ` [PATCH 0/7] v4.19-stable randconfig fixes Sasha Levin
2018-12-18 15:12   ` Greg Kroah-Hartman
2018-12-18 16:20     ` Sasha Levin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).