Guenter Roeck | 27 Apr 20:12 2015

[PATCH] util_macros.h: Have array pointer point to array of constants

Using the new find_closest() macro can result in the following sparse

drivers/hwmon/lm85.c:194:16: warning:
		incorrect type in initializer (different modifiers)
drivers/hwmon/lm85.c:194:16:    expected int *__fc_a
drivers/hwmon/lm85.c:194:16:    got int static const [toplevel] *<noident>
drivers/hwmon/lm85.c:210:16: warning:
		incorrect type in initializer (different modifiers)
drivers/hwmon/lm85.c:210:16:    expected int *__fc_a
drivers/hwmon/lm85.c:210:16:    got int const *map

This is because the array passed to find_closest() will typically be
declared as array of constants, but the macro declares a non-constant
pointer to it.

Cc: Andrew Morton <akpm <at>>
Cc: Bartosz Golaszewski <bgolaszewski <at>>
Signed-off-by: Guenter Roeck <linux <at>>
 include/linux/util_macros.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/linux/util_macros.h b/include/linux/util_macros.h
index d5f4fb69dba3..f9b2ce58039b 100644
--- a/include/linux/util_macros.h
+++ b/include/linux/util_macros.h
 <at>  <at>  -5,7 +5,7  <at>  <at> 
 ({									\
 	typeof(as) __fc_i, __fc_as = (as) - 1;				\
(Continue reading)

Murali Karicheri | 27 Apr 20:12 2015

[PATCH v2] net: netcp: remove call to netif_carrier_(on/off) for MAC to Phy interface

Currently when interface type is MAC to Phy, netif_carrier_(on/off)
is called which is not needed as Phy lib already updates the carrier
status to net stack. This is needed only for other interface types

Signed-off-by: Murali Karicheri <m-karicheri2 <at>>
 - v2: re-send to apply this on v4.1
 - Fixed comment against initial version
 - Ok to apply this to net-next. So changed subject prefix to reflect the same

 drivers/net/ethernet/ti/netcp_ethss.c |    8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/drivers/net/ethernet/ti/netcp_ethss.c b/drivers/net/ethernet/ti/netcp_ethss.c
index 2bef655..9b7e0a3 100644
--- a/drivers/net/ethernet/ti/netcp_ethss.c
+++ b/drivers/net/ethernet/ti/netcp_ethss.c
 <at>  <at>  -1765,7 +1765,9  <at>  <at>  static void netcp_ethss_link_state_action(struct gbe_priv *gbe_dev,

-		if (ndev && slave->open)
+		if (ndev && slave->open &&
+		    slave->link_interface != SGMII_LINK_MAC_PHY &&
+		    slave->link_interface != XGMII_LINK_MAC_PHY)
 	} else {
 		writel(mac_control, GBE_REG_ADDR(slave, emac_regs,
 <at>  <at>  -1773,7 +1775,9  <at>  <at>  static void netcp_ethss_link_state_action(struct gbe_priv *gbe_dev,
 		cpsw_ale_control_set(gbe_dev->ale, slave->port_num,
(Continue reading)

David Miller | 27 Apr 19:56 2015

[GIT] Networking

1) mlx4 doesn't check fully for supported valid RSS hash function, fix from
   Amir Vadai.

2) Off by one in ibmveth_change_mtu(), from David Gibson.

3) Prevent altera chip from reporting false error interrupts in some
   circumstances, from Chee Nouk Phoon.

4) Get rid of that stupid endless loop trying to allocate a FIN packet
   in TCP, and in the process kill deadlocks.  From Eric Dumazet.

5) Fix get_rps_cpus() crash due to wrong invalid-cpu value, also from
   Eric Dumazet.

6) Fix two bugs in async rhashtable resizing, from Thomas Graf.

7) Fix topology server listener socket namespace bug in TIPC, from
   Ying Xue.

8) Add some missing HAS_DMA kconfig dependencies, from Geert

9) bgmac driver intends to force re-polling but does so by returning
   the wrong value from it's ->poll() handler.  Fix from Rafał

10) When the creater of an rhashtable configures a max size for it,
    don't bark in the logs and drop insertions when that is exceeded.
    Fix from Johannes Berg.
(Continue reading)

Tomasz Duszynski | 27 Apr 19:18 2015

[PATCH v3] iio: light: add support for ROHM BH1710/BH1715/BH1721/BH1750/BH1751 ambient light sensors

Add support for ROHM BH1710/BH1715/BH1721/BH1750/BH1751 ambient light

Signed-off-by: Tomasz Duszynski <tduszyns <at>>
 Changes in v3:
 	- Do some code cleanup
	- Add comments to clarify non-intuitive driver parts
	- Return proper scale value [lx / count] to userspace. In previous
	  patches scale inverse was returned.

 Changes in v2:
 	- Store chip-dependent values in chip_info structure
	- Add bh1750_remove to power down chip (necessary for BH1721)
	- Use one time mode for chips that have support for that
	- Use IIO_LIGHT instead of IIO_INTENSITY for channel type

 drivers/iio/light/Kconfig  |  10 ++
 drivers/iio/light/Makefile |   1 +
 drivers/iio/light/bh1750.c | 334 +++++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 345 insertions(+)
 create mode 100644 drivers/iio/light/bh1750.c

diff --git a/drivers/iio/light/Kconfig b/drivers/iio/light/Kconfig
index 5a3237b..ebc578a 100644
--- a/drivers/iio/light/Kconfig
+++ b/drivers/iio/light/Kconfig
 <at>  <at>  -37,6 +37,16  <at>  <at>  config APDS9300
 	 To compile this driver as a module, choose M here: the
 	 module will be called apds9300.
(Continue reading)

Fabian Frederick | 27 Apr 19:23 2015

[PATCH 1/1 linux-next] fs/coda/upcall.c: remove UPARG flow control macro

Move UPARG code to alloc_upcall() and test errors/return in callsites.
This patch removes flow control in macros which must be avoided.
(See Documentation/CodingStyle)

Signed-off-by: Fabian Frederick <fabf <at>>
This is untested.

 fs/coda/upcall.c | 107 +++++++++++++++++++++++++++++++++++--------------------
 1 file changed, 69 insertions(+), 38 deletions(-)

diff --git a/fs/coda/upcall.c b/fs/coda/upcall.c
index 9b1ffaa..7524f630 100644
--- a/fs/coda/upcall.c
+++ b/fs/coda/upcall.c
 <at>  <at>  -41,30 +41,24  <at>  <at> 
 static int coda_upcall(struct venus_comm *vc, int inSize, int *outSize,
 		       union inputArgs *buffer);

-static void *alloc_upcall(int opcode, int size)
+static int alloc_upcall(int opcode, int insize, int *outsize,
+			union inputArgs **inp, union outputArgs **outp)
-	union inputArgs *inp;
+	CODA_ALLOC(*inp, union inputArgs *, insize);
+	if (!*inp)
+		return -ENOMEM;

-	CODA_ALLOC(inp, union inputArgs *, size);
-        if (!inp)
(Continue reading)

Stas Sergeev | 27 Apr 19:08 2015

[PATCH v2 0/3] leds: blink resolution improvements


The following patches improve the precision of led
timer trigger and add the delay unit control.
That allows to make PWM brightness control with timer
Arnaldo Carvalho de Melo | 27 Apr 19:04 2015

[GIT PULL 0/7] perf/urgent fixes

Hi Ingo,

	Please consider pulling, this is on top of my previous 'perf-urgent-for-mingo'
pull request.

- Arnaldo

The following changes since commit de28c15daf60e9625bece22f13a091fac8d05f1d:

  tools lib api: Undefine _FORTIFY_SOURCE before setting it (2015-04-23 17:08:23 -0300)

are available in the git repository at:

  git:// tags/perf-urgent-for-mingo-2

for you to fetch changes up to 1d90a685eb75a56648d7dd22c704a1a6da516de9:

  perf bench numa: Fix immediate meeting of convergence condition (2015-04-27 13:57:50 -0300)

perf/urgent fixes:

User visible:

. Fix a segfault in 'perf top' when kernel map is restricted (Wang Nan)

. Fix hung wakeup tasks after requeueing in 'perf bench futex' (Davidlohr Bueso)

. Fix bug in perf probe global variables handling, missing curly braces on
  an if body (He Kuang)
(Continue reading)

Luis R. Rodriguez | 27 Apr 18:43 2015

[PATCH v2] ivtv: use arch_phys_wc_add() and require PAT disabled

From: "Luis R. Rodriguez" <mcgrof <at>>

We are burrying direct access to MTRR code support on
x86 in order to take advantage of PAT. In the future we
also want to make the default behaviour of ioremap_nocache()
to use strong UC, use of mtrr_add() on those systems
would make write-combining void.

In order to help both enable us to later make strong
UC default and in order to phase out direct MTRR access
code port the driver over to arch_phys_wc_add() and
annotate that the device driver requires systems to
boot with PAT disabled, with the nopat kernel parameter.

This is a worthy comprmise given that the hardware is
really rare these days, and perhaps only some lost souls
in some third world country are expected to be using this
feature of the device driver.

Cc: Andy Walls <awalls <at>>
Cc: Mauro Carvalho Chehab <mchehab <at>>
Cc: Andy Lutomirski <luto <at>>
Cc: Suresh Siddha <sbsiddha <at>>
Cc: Ingo Molnar <mingo <at>>
Cc: Thomas Gleixner <tglx <at>>
Cc: Juergen Gross <jgross <at>>
Cc: Daniel Vetter <daniel.vetter <at>>
Cc: Dave Airlie <airlied <at>>
Cc: Bjorn Helgaas <bhelgaas <at>>
Cc: Antonino Daplas <adaplas <at>>
(Continue reading)

Aravind Gopalakrishnan | 27 Apr 17:25 2015

[PATCH] x86, amd: Set X86_FEATURE_EXTD_APICID for future processors

Decision to use a 4-bit mask or 8-bit mask in default_get_apic_id()
is controlled by setting capability bit X86_FEATURE_EXTD_APICID.

Currently, we detect extended APIC ID support by accessing Link
Transaction Control register D18F0x68 in PCI config space.

But, not even that is needed as we can safely postulate that future
AMD processors will support 8-bit APIC IDs and we can simply set that
feature bit on them, without the PCI access.

Signed-off-by: Aravind Gopalakrishnan <Aravind.Gopalakrishnan <at>>
 arch/x86/kernel/cpu/amd.c | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)

diff --git a/arch/x86/kernel/cpu/amd.c b/arch/x86/kernel/cpu/amd.c
index fd470eb..20b6813 100644
--- a/arch/x86/kernel/cpu/amd.c
+++ b/arch/x86/kernel/cpu/amd.c
 <at>  <at>  -520,8 +520,16  <at>  <at>  static void early_init_amd(struct cpuinfo_x86 *c)
 			set_cpu_cap(c, X86_FEATURE_K6_MTRR);
 #if defined(CONFIG_X86_LOCAL_APIC) && defined(CONFIG_PCI)
-	/* check CPU config space for extended APIC ID */
-	if (cpu_has_apic && c->x86 >= 0xf) {
+	/*
+	 * ApicID can always be treated as a 8bit value for
+	 * AMD APIC versions >= 0x10. So, we can safely set
+	 * X86_FEATURE_EXTD_APICID unconditionally for
+	 * families after 16h.
(Continue reading)

Geert Uytterhoeven | 27 Apr 17:00 2015

[PATCH] ARM: gic: Document Power and Clock Domain optional properties

On some SoCs, the GIC may be part of a PM Domain (hardware Power and/or
Clock Domain).  Document the related optional DT properties.

Note: As the current GIC driver doesn't support Runtime PM yet, PM
Domain constraints must be handled elsewhere in e.g. platform code.

Signed-off-by: Geert Uytterhoeven <geert+renesas <at>>
To preserve DT stability, we would like to add these properties to the
affected shmobile dtsi files.

On Thu, Mar 26, 2015 at 11:39 AM, Marc Zyngier <marc.zyngier <at>> wrote:
> On 25/03/15 21:19, Geert Uytterhoeven wrote:
>> I would like to add the clock and GIC dependency on the clock in the DTS now,
>> for reasons of DTS stability. But that means I need a temporary workaround
>> to avoid the clock from being disabled, until the GIC driver handles this.
>> I don't expect a fix for the GIC code to just show up magically. I just wanted
>> you to be aware of the problem. GIC is not the only problematic module here,
>> there are others, cfr. the last slide of [2].
> As long as there is an agreement from the DT people on the presence of
> that extra property in the GIC node, I'm happy with that. I'd like it to
> be documented though.

Full thread at

 Documentation/devicetree/bindings/arm/gic.txt | 8 ++++++++
 1 file changed, 8 insertions(+)
(Continue reading)

Jean Delvare | 27 Apr 16:41 2015

[PATCH] firmware: dmi: List my quilt tree

I'll be maintaining the pending patches to the dmi_scan and dmi-id
drivers as a quilt tree.

Signed-off-by: Jean Delvare <jdelvare <at>>
 1 file changed, 1 insertion(+)

--- linux-4.1-rc1.orig/MAINTAINERS	2015-04-27 16:33:57.946487307 +0200
+++ linux-4.1-rc1/MAINTAINERS	2015-04-27 16:38:49.203470162 +0200
 <at>  <at>  -3274,6 +3274,7  <at>  <at>  F:	drivers/hwmon/dme1737.c
 M:	Jean Delvare <jdelvare <at>>
 S:	Maintained
+T:	quilt
 F:	Documentation/ABI/testing/sysfs-firmware-dmi-tables
 F:	drivers/firmware/dmi-id.c
 F:	drivers/firmware/dmi_scan.c


Jean Delvare
SUSE L3 Support