Vincent Guittot | 4 May 09:17 2016

[RFC PATCH] sched: reflect sched_entity movement into task_group's utilization

Ensure that changes of the utilization of a sched_entity will be
reflected in the task_group hierarchy down to the root cfs.

This patch tries another way than the flat utilization hierarchy proposal to
ensure that the changes will be propagated down to the root cfs.

The way to compute the sched average metrics stays the same so the utilization
only need to be synced with the local cfs rq timestamp.

We keep an estimate of the utilization of each task group which is not used
for now but might be usefull in the future even if i don't have idea so far. 

Signed-off-by: Vincent Guittot <vincent.guittot <at> linaro.org>
---
 kernel/sched/fair.c  | 95 +++++++++++++++++++++++++++++++++++++++++++++++++++-
 kernel/sched/sched.h |  1 +
 2 files changed, 95 insertions(+), 1 deletion(-)

diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
index b8a33ab..7861590 100644
--- a/kernel/sched/fair.c
+++ b/kernel/sched/fair.c
 <at>  <at>  -2575,10 +2575,87  <at>  <at>  static void update_cfs_shares(struct cfs_rq *cfs_rq)

 	reweight_entity(cfs_rq_of(se), se, shares);
 }
+
+/*
+ * Save how much utilization has just been added/removed on cfs rq so we can
+ * propagate it across the whole tg tree
(Continue reading)

Paul Mackerras | 4 May 08:51 2016

Regression in v4.6-rc due to SCSI multipath change

Current upstream kernels fail to boot on my POWER8 server with
multipath SCSI disks and IPR host bus adapters.  What happens is that
the system finds each disk twice (as normal) and then prints messages
like this:

[    2.827761] sd 1:2:4:0: alua: supports implicit TPGS
[    2.827875] sd 1:2:4:0: alua: No device descriptors found
[    2.827923] sd 1:2:4:0: alua: Attach failed (-22)
[    2.827979] device-mapper: table: 253:0: multipath: error attaching hardware handler
[    2.828048] device-mapper: ioctl: error adding target to table

Eventually dracut times out (this is with Fedora 23) enters emergency
mode.

I bisected the problem down to commit 0047220c6c36 ("scsi_dh_alua: use
unique device id", 2016-02-19).  It seems that this commit adds the
restriction that we can only do multipath with disks that have stuff
in their VPD page 83 that scsi_vpd_lun_id() can parse.  The disks on
my server apparently don't.

I instrumented scsi_vpd_lun_id() to find out what was going on.  The
disks on this machine have a vendor-specific designator and a T10
vendor ID based designator, but no designators of types 2, 3 or 8.
An example from one disk is:

02 01 00 20 49 42 4d 20 20 20 20 20 49 50 52 2d 30 20 20 20 35 45 43
34 41 42 30 30 30 30 30 30 30 30 32 30

02 00 00 14 30 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20

(Continue reading)

Wanpeng Li | 4 May 08:45 2016
Picon

[PATCH] sched/nohz: fix affine unpinned timers mess

From: Wanpeng Li <wanpeng.li <at> hotmail.com>

'commit 9642d18eee2c ("nohz: Affine unpinned timers to housekeepers")'
intended to affine unpinned timers to housekeepers:

unpinned timers(full dynaticks, idle)   =>   nearest busy housekeepers(otherwise, fallback to any housekeepers)
unpinned timers(full dynaticks, busy)   =>   nearest busy housekeepers(otherwise, fallback to any housekeepers)
unpinned timers(houserkeepers, idle)    =>   nearest busy housekeepers(otherwise, fallback to itself)

However, the !idle_cpu(i) && is_housekeeping_cpu(cpu) check modify the 
intention to:

unpinned timers(full dynaticks, idle)   =>   any housekeepers(no mattter cpu topology)
unpinned timers(full dynaticks, busy)   =>   any housekeepers(no mattter cpu topology)
unpinned timers(housekeepers, idle)     =>   any busy cpus(otherwise, fallback to any housekeepers)

This patch fix it by checking if there is busy housekeepers nearby,
otherwise fallback to any housekeepers/itself, after the patch:

unpinned timers(full dynaticks, idle)   =>   nearest busy housekeepers(otherwise, fallback to any housekeepers)
unpinned timers(full dynaticks, busy)   =>   nearest busy housekeepers(otherwise, fallback to any housekeepers)
unpinned timers(housekeepers, idle)     =>   nearest busy housekeepers(otherwise, fallback to itself)

Fixes: 'commit 9642d18eee2c ("nohz: Affine unpinned timers to housekeepers")' 
Cc: Frederic Weisbecker <fweisbec <at> gmail.com>
Cc: Peter Zijlstra <peterz <at> infradead.org>
Cc: Thomas Gleixner <tglx <at> linutronix.de> 
Cc: Ingo Molnar <mingo <at> kernel.org>
Signed-off-by: Wanpeng Li <wanpeng.li <at> hotmail.com>
---
(Continue reading)

Dan Carpenter | 4 May 08:16 2016
Picon

[patch] rtlwifi: rtl818x: silence uninitialized variable warning

What about if "rtlphy->pwrgroup_cnt" is 2?  In that case we would use an
uninitialized "chnlgroup" variable and probably crash.  Maybe that can't
happen for some reason which is not obvious but in that case this patch
is harmless.

Setting it to zero seems like a standard default in the surrounding code
so it's probably fine here as well.

Signed-off-by: Dan Carpenter <dan.carpenter <at> oracle.com>

diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8192se/rf.c b/drivers/net/wireless/realtek/rtlwifi/rtl8192se/rf.c
index 78a81c1..9475aa2 100644
--- a/drivers/net/wireless/realtek/rtlwifi/rtl8192se/rf.c
+++ b/drivers/net/wireless/realtek/rtlwifi/rtl8192se/rf.c
 <at>  <at>  -208,8 +208,7  <at>  <at>  static void _rtl92s_get_txpower_writeval_byregulatory(struct ieee80211_hw *hw,
 				 "Realtek regulatory, 40MHz, writeval = 0x%x\n",
 				 writeval);
 		} else {
-			if (rtlphy->pwrgroup_cnt == 1)
-				chnlgroup = 0;
+			chnlgroup = 0;

 			if (rtlphy->pwrgroup_cnt >= 3) {
 				if (chnl <= 3)

Dan Carpenter | 4 May 08:13 2016
Picon

[patch] [SCSI] eata_pio: missing break statement

This missing break statement bug predates git.  It's a very minor thing,
it means that we print a '?' instead of a 'z' in dmesg.

Signed-off-by: Dan Carpenter <dan.carpenter <at> oracle.com>

diff --git a/drivers/scsi/eata_pio.c b/drivers/scsi/eata_pio.c
index ca8003f..4299fa4 100644
--- a/drivers/scsi/eata_pio.c
+++ b/drivers/scsi/eata_pio.c
 <at>  <at>  -729,6 +729,7  <at>  <at>  static int register_pio_HBA(long base, struct get_conf *gc, struct pci_dev *pdev
 		break;
 	case 0x24:
 		SD(sh)->EATA_revision = 'z';
+		break;
 	default:
 		SD(sh)->EATA_revision = '?';
 	}

Stephen Rothwell | 4 May 07:52 2016
Picon
Picon

linux-next: build warning after merge of the lightnvm tree

Hi Matias,

After merging the lightnvm tree, today's linux-next build (powerpc
allyesconfig) produced this warning:

In file included from include/linux/swab.h:4:0,
                 from include/uapi/linux/byteorder/big_endia
n.h:12,
                 from include/linux/byteorder/big_endian.h:4
,
                 from arch/powerpc/include/uapi/asm/byteorde
r.h:13,
                 from include/asm-generic/bitops/le.h:5,
                 from arch/powerpc/include/asm/bitops.h:279,
                 from include/linux/bitops.h:36,
                 from include/linux/kernel.h:10,
                 from include/linux/list.h:8,
                 from include/linux/pci.h:25,
                 from drivers/nvme/host/nvme.h:18,
                 from drivers/nvme/host/lightnvm.c:23:
drivers/nvme/host/lightnvm.c: In function 'nvme_nvm_rqtocmd'
:
include/uapi/linux/byteorder/big_endian.h:30:52: warning: passing argument 1 of '__fswab64' makes
integer from pointer without a cast [-Wint-conversion]
 #define __cpu_to_le64(x) ((__force __le64)__swab64((x)))
                                                    ^
include/uapi/linux/swab.h:126:12: note: in definition of macro '__swab64'
  __fswab64(x))
            ^
include/linux/byteorder/generic.h:85:21: note: in expansion of macro '__cpu_to_le64'
(Continue reading)

Rajesh Bhagat | 4 May 05:41 2016

[PATCH] drivers: usb: dwc3 : Configure DMA properties and ops from DT

On certain platforms (e.g. ARM64) the dma_ops needs to be explicitly set
to be able to do DMA allocations, so use the of_dma_configure() helper
to populate the dma properties and assign an appropriate dma_ops.

Signed-off-by: Rajesh Bhagat <rajesh.bhagat <at> nxp.com>
Reviewed-by: Yang-Leo Li <leoyang.li <at> nxp.com>
---
 drivers/usb/dwc3/host.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/usb/dwc3/host.c b/drivers/usb/dwc3/host.c
index c679f63..4d5b783 100644
--- a/drivers/usb/dwc3/host.c
+++ b/drivers/usb/dwc3/host.c
 <at>  <at>  -17,6 +17,7  <at>  <at> 

 #include <linux/platform_device.h>
 #include <linux/usb/xhci_pdriver.h>
+#include <linux/of_device.h>

 #include "core.h"

 <at>  <at>  -32,6 +33,9  <at>  <at>  int dwc3_host_init(struct dwc3 *dwc)
 		return -ENOMEM;
 	}

+	if (IS_ENABLED(CONFIG_OF) && dwc->dev->of_node)
+		of_dma_configure(&xhci->dev, dwc->dev->of_node);
+
 	dma_set_coherent_mask(&xhci->dev, dwc->dev->coherent_dma_mask);
(Continue reading)

Yuyang Du | 3 May 22:02 2016
Picon

[PATCH v3 00/12] sched/fair: Optimize and clean up sched averages

Hi Peter,

This patch series combines the previous cleanup and optimization
series. And as you and Ingo suggested, the increased kernel load
scale is reinstated when on 64BIT and FAIR_GROUP_SCHED.

This patch series should have no perceivable changes to load
and util except that load's range is increased by 1024 times.

My initial tests suggest that, see this previous post's link for
the figures: http://article.gmane.org/gmane.linux.kernel/2213506.
The workload is running 100us out of every 200us, and 2000us out
of every 8000us. Again fixed workload, fixed CPU, and fixed freq.

And I believe the codes should be cleaner and more efficient after
these patches.

The changes leading to this version include changelog and code
comment reword according to Peter's comments.

Thanks,
Yuyang

Yuyang Du (12):
  sched/fair: Optimize sum computation with a lookup table
  sched/fair: Rename variable names for sched averages
  sched/fair: Change the variable to hold the number of periods to
    32bit
  sched/fair: Add __always_inline compiler attribute to
    __accumulate_sum()
(Continue reading)

kernel test robot | 4 May 05:13 2016
Picon

[serial] 13a7238eea: WARNING: CPU: 0 PID: 1 at drivers/tty/serial/serial_core.c:99 uart_change_pm+0x35/0x162


FYI, we noticed the following commit:

https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty.git tty-testing
commit 13a7238eeab5718bf968e2a835205ba659a38a77 ("serial: core: Prevent unsafe uart port access,
part 3")

on test machine: vm-vp-quantal-x86_64: 2 threads qemu-system-x86_64 -enable-kvm with 360M memory

caused below changes:

[    7.249323] ------------[ cut here ]------------
[    7.249323] ------------[ cut here ]------------
[    7.250172] WARNING: CPU: 0 PID: 1 at drivers/tty/serial/serial_core.c:99 uart_change_pm+0x35/0x162
[    7.250172] WARNING: CPU: 0 PID: 1 at drivers/tty/serial/serial_core.c:99 uart_change_pm+0x35/0x162
[    7.252110] Modules linked in:
[    7.252110] Modules linked in:

[    7.252679] CPU: 0 PID: 1 Comm: swapper/0 Tainted: G    B           4.6.0-rc5-00015-g13a7238 #1
[    7.252679] CPU: 0 PID: 1 Comm: swapper/0 Tainted: G    B           4.6.0-rc5-00015-g13a7238 #1
[    7.254232] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS Debian-1.8.2-1 04/01/2014
[    7.254232] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS Debian-1.8.2-1 04/01/2014
[    7.255806]  0000000000000000
[    7.255806]  0000000000000000 ffff88000f42f668 ffff88000f42f668 ffffffff815a2566 ffffffff815a2566
0000000000000286 0000000000000286

[    7.257180]  0000000041b58ab3
[    7.257180]  0000000041b58ab3 ffffffff81f66067 ffffffff81f66067 ffffffff815a240c ffffffff815a240c
ffffffff81f7647d ffffffff81f7647d

(Continue reading)

buzdelabuz2 | 4 May 05:12 2016
Picon

[PATCH 1/2] Improve types abstraction for gdb python scripts

From: Dom Cote <buzdelabuz2+git <at> gmail.com>

Change the read_u16 function so it accepts both 'str' and 'byte'
as type for the arguments.

When calling read_memory() from gdb API, depending on if
it was built with 2.7 or 3.X, the format used to return the
data will differ ( 'str' for 2.7, and 'byte' for 3.X ).

Add a function read_memoryview() to be able to get a
'memoryview' object back from read_memory() both with
python 2.7 and 3.X .

Tested with python 3.4 and 2.7
Tested with gdb 7.7

Signed-off-by: Dom Cote <buzdelabuz2+git <at> gmail.com>
---
 scripts/gdb/linux/utils.py | 17 +++++++++++++++--
 1 file changed, 15 insertions(+), 2 deletions(-)

diff --git a/scripts/gdb/linux/utils.py b/scripts/gdb/linux/utils.py
index 0893b326a28b..dba6c88ea7b9 100644
--- a/scripts/gdb/linux/utils.py
+++ b/scripts/gdb/linux/utils.py
 <at>  <at>  -87,11 +87,24  <at>  <at>  def get_target_endianness():
     return target_endianness

 
+def read_memoryview(inf, start, length):
(Continue reading)

buzdelabuz2 | 4 May 05:08 2016
Picon

[PATCH 1/2] Improve types abstraction for gdb python scripts

From: Dom Cote <buzdelabuz2+git <at> gmail.com>

Change the read_u16 function so it accepts both 'str' and 'byte'
as type for the arguments.

When calling read_memory() from gdb API, depending on if
it was built with 2.7 or 3.X, the format used to return the
data will differ ( 'str' for 2.7, and 'byte' for 3.X ).

Add a function read_memoryview() to be able to get a
'memoryview' object back from read_memory() both with
python 2.7 and 3.X .

Tested with python 3.4 and 2.7
Tested with gdb 7.7

Signed-off-by: Dom Cote <buzdelabuz2+git <at> gmail.com>
---
 scripts/gdb/linux/utils.py | 17 +++++++++++++++--
 1 file changed, 15 insertions(+), 2 deletions(-)

diff --git a/scripts/gdb/linux/utils.py b/scripts/gdb/linux/utils.py
index 0893b326a28b..dba6c88ea7b9 100644
--- a/scripts/gdb/linux/utils.py
+++ b/scripts/gdb/linux/utils.py
 <at>  <at>  -87,11 +87,24  <at>  <at>  def get_target_endianness():
     return target_endianness

 
+def read_memoryview(inf, start, length):
(Continue reading)


Gmane