Re: [PATCH v2] net/mlx5e: Use refcount_t for refcount

2019-08-06 Thread Leon Romanovsky
On Mon, Aug 05, 2019 at 08:06:36PM +, Saeed Mahameed wrote: > On Mon, 2019-08-05 at 14:55 +0800, Chuhong Yuan wrote: > > On Mon, Aug 5, 2019 at 2:13 PM Leon Romanovsky > > wrote: > > > On Sun, Aug 04, 2019 at 10:44:47PM +0800, Chuhong Yuan wrote: > > > > On Sun, Aug 4, 2019 at 8:59 PM Leon Rom

[PATCH] ALSA: usb-audio: fix a memory leak bug

2019-08-06 Thread Wenwen Wang
In snd_usb_get_audioformat_uac3(), a structure for channel maps 'chmap' is allocated through kzalloc() before the execution goto 'found_clock'. However, this structure is not deallocated if the memory allocation for 'pd' fails, leading to a memory leak bug. To fix the above issue, free 'fp->chmap'

Unrelated question and threading (was: Bisected: Kernel 4.14 + has 3 times higher write IO latency than Kernel 4.4 with raid1)

2019-08-06 Thread Paul Menzel
Dear Rick, It looks like your message is unrelated to the thread at hand. Therefore, please start a new thread by *not* using the reply feature, but create a new message in your mail program (MUA). Please read some mailing list etiquettes on the Web like [1]. Kind regards, Paul [1]: htt

Re: [PATCH 16/16] dt-bindings: net: add bindings for ADIN PHY driver

2019-08-06 Thread Ardelean, Alexandru
On Mon, 2019-08-05 at 16:11 +0200, Andrew Lunn wrote: > [External] > > > + adi,rx-internal-delay: > > +$ref: /schemas/types.yaml#/definitions/uint32 > > +description: | > > + RGMII RX Clock Delay used only when PHY operates in RGMII mode > > (phy-mode > > + is "rgmii-id", "rgmi

Re: [RFC PATCH v3 00/16] Core scheduling v3

2019-08-06 Thread Aaron Lu
On 2019/8/6 14:56, Aubrey Li wrote: > On Tue, Aug 6, 2019 at 11:24 AM Aaron Lu wrote: >> I've been thinking if we should consider core wide tenent fairness? >> >> Let's say there are 3 tasks on 2 threads' rq of the same core, 2 tasks >> (e.g. A1, A2) belong to tenent A and the 3rd B1 belong to ano

Re: [PATCH RFC] mm/memcontrol: reclaim severe usage over high limit in get_user_pages loop

2019-08-06 Thread Michal Hocko
On Mon 05-08-19 20:28:40, Yang Shi wrote: > On Mon, Aug 5, 2019 at 7:32 AM Michal Hocko wrote: > > > > On Fri 02-08-19 11:56:28, Yang Shi wrote: > > > On Fri, Aug 2, 2019 at 2:35 AM Michal Hocko wrote: > > > > > > > > On Thu 01-08-19 14:00:51, Yang Shi wrote: > > > > > On Mon, Jul 29, 2019 at 11:

Re: [PATCH] scsi/megaraid_sas: fix a compilation warning

2019-08-06 Thread Sumit Saxena
On Fri, Jul 26, 2019 at 7:55 PM Qian Cai wrote: > > The commit de516379e85f ("scsi: megaraid_sas: changes to function > prototypes") introduced a comilation warning due to it changed the > function prototype of read_fw_status_reg() to take an instance pointer > instead, but forgot to remove an unu

Re: [PATCH RFC] mm/memcontrol: reclaim severe usage over high limit in get_user_pages loop

2019-08-06 Thread Michal Hocko
On Fri 02-08-19 13:44:38, Michal Hocko wrote: [...] > > > diff --git a/mm/memcontrol.c b/mm/memcontrol.c > > > index ba9138a4a1de..53a35c526e43 100644 > > > --- a/mm/memcontrol.c > > > +++ b/mm/memcontrol.c > > > @@ -2429,8 +2429,12 @@ static int try_charge(struct mem_cgroup *memcg, > > > gfp_t gf

[PATCH] media: rc: add include guard to rc-map.h

2019-08-06 Thread Masahiro Yamada
Add a header include guard just in case. Signed-off-by: Masahiro Yamada --- include/media/rc-map.h | 5 + 1 file changed, 5 insertions(+) diff --git a/include/media/rc-map.h b/include/media/rc-map.h index bebd3c4c6338..4e0873f6e853 100644 --- a/include/media/rc-map.h +++ b/include/media/rc

Re: XFS segementation fault with new linux 4.19.63

2019-08-06 Thread Christoph Hellwig
[adding the linux-xfs list] On Wed, Jul 31, 2019 at 03:01:33PM +0200, Kinky Nekoboi wrote: > I am not subscribed, so if you want to contact me do Direkt Email. > > kern output: > > > ul 31 13:51:53 lain kernel: [   71.660736] XFS: Assertion failed: > xfs_perag_resv(pag, XFS_AG_RESV_METADATA)->a

[PATCH v2] checkpatch: exclude sizeof sub-expressions from MACRO_ARG_REUSE

2019-08-06 Thread Brendan Jackman
The arguments of sizeof are not evaluated so arguments are safe to re-use in that context. Excluding sizeof sub-expressions means macros like ARRAY_SIZE can pass checkpatch. Cc: Andy Whitcroft Cc: Joe Perches Signed-off-by: Brendan Jackman --- v2 is the same patch, I just forgot to add CCs to

Re: XFS segementation fault with new linux 4.19.63

2019-08-06 Thread Kinky Nekoboi
Addional info: this only occurs if kernel is compiled with: CONFIG_XFS_DEBUG=y running 4.19.64 without xfs debugging works fine Am 06.08.19 um 09:08 schrieb Christoph Hellwig: > [adding the linux-xfs list] > > On Wed, Jul 31, 2019 at 03:01:33PM +0200, Kinky Nekoboi wrote: >> I am not subscribed

Re: [PATCH 3/4] csky/dma: Fixup cache_op failed when cross memory ZONEs

2019-08-06 Thread Guo Ren
On Tue, Aug 6, 2019 at 2:49 PM Christoph Hellwig wrote: > > On Tue, Jul 30, 2019 at 08:15:44PM +0800, guo...@kernel.org wrote: > > diff --git a/arch/csky/mm/dma-mapping.c b/arch/csky/mm/dma-mapping.c > > index 80783bb..3f1ff9d 100644 > > --- a/arch/csky/mm/dma-mapping.c > > +++ b/arch/csky/mm/dma-

Re: [PATCH -next] scsi: megaraid_sas: Make a bunch of functions static

2019-08-06 Thread Sumit Saxena
On Fri, Jul 26, 2019 at 7:26 PM YueHaibing wrote: > > Fix sparse warnings: > > drivers/scsi/megaraid/megaraid_sas_fusion.c:3369:1: warning: symbol > 'complete_cmd_fusion' was not declared. Should it be static? > drivers/scsi/megaraid/megaraid_sas_fusion.c:3535:6: warning: symbol > 'megasas_sync_

Re: [PATCH 15/16] net: phy: adin: add ethtool get_stats support

2019-08-06 Thread Ardelean, Alexandru
On Mon, 2019-08-05 at 17:28 +0200, Andrew Lunn wrote: > [External] > > > +struct adin_hw_stat { > > + const char *string; > > +static void adin_get_strings(struct phy_device *phydev, u8 *data) > > +{ > > + int i; > > + > > + for (i = 0; i < ARRAY_SIZE(adin_hw_stats); i++) { > > + m

[PATCH] auxdisplay: charlcd: add include guard to charlcd.h

2019-08-06 Thread Masahiro Yamada
Add a header include guard just in case. Signed-off-by: Masahiro Yamada --- drivers/auxdisplay/charlcd.h | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/auxdisplay/charlcd.h b/drivers/auxdisplay/charlcd.h index 8cf6c18b0adb..00911ad0f3de 100644 --- a/drivers/auxdisplay/charlcd.

[PATCH 2/2] auxdisplay: charlcd: add include guard to charlcd.h

2019-08-06 Thread Masahiro Yamada
Add a header include guard just in case. Signed-off-by: Masahiro Yamada --- drivers/auxdisplay/charlcd.h | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/auxdisplay/charlcd.h b/drivers/auxdisplay/charlcd.h index 8cf6c18b0adb..00911ad0f3de 100644 --- a/drivers/auxdisplay/charlcd.

[PATCH 1/2] auxdisplay: charlcd: move charlcd.h to drivers/auxdisplay

2019-08-06 Thread Masahiro Yamada
This header is included in drivers/auxdisplay/. Make it a local header. Signed-off-by: Masahiro Yamada --- drivers/auxdisplay/charlcd.c | 2 +- {include/misc => drivers/auxdisplay}/charlcd.h | 0 drivers/auxdisplay/hd44780.c | 3 +-- drivers/auxdisplay/panel.

Build regressions/improvements in v5.3-rc3

2019-08-06 Thread Geert Uytterhoeven
Below is the list of build error/warning regressions/improvements in v5.3-rc3[1] compared to v5.2[2]. Summarized: - build errors: +9/-1 - build warnings: +133/-170 JFYI, when comparing v5.3-rc3[1] to v5.3-rc2[3], the summaries are: - build errors: +0/-1 - build warnings: +59/-99 Note tha

Re: [PATCH 4.14 00/53] 4.14.137-stable review

2019-08-06 Thread Jack Wang
Greg Kroah-Hartman 于2019年8月5日周一 下午3:14写道: > > This is the start of the stable review cycle for the 4.14.137 release. > There are 53 patches in this series, all will be posted as a response > to this one. If anyone has any issues with these being applied, please > let me know. > > Responses should

Re: [PATCH 15/16] net: phy: adin: add ethtool get_stats support

2019-08-06 Thread Ardelean, Alexandru
On Mon, 2019-08-05 at 17:30 +0200, Andrew Lunn wrote: > [External] > > On Mon, Aug 05, 2019 at 07:54:52PM +0300, Alexandru Ardelean wrote: > > This change implements retrieving all the error counters from the PHY. > > The PHY supports several error counters/stats. The `Mean Square Errors` > > stat

Re: [PATCH 3/4] csky/dma: Fixup cache_op failed when cross memory ZONEs

2019-08-06 Thread Christoph Hellwig
On Tue, Aug 06, 2019 at 03:11:13PM +0800, Guo Ren wrote: > On Tue, Aug 6, 2019 at 2:49 PM Christoph Hellwig wrote: > > > > On Tue, Jul 30, 2019 at 08:15:44PM +0800, guo...@kernel.org wrote: > > > diff --git a/arch/csky/mm/dma-mapping.c b/arch/csky/mm/dma-mapping.c > > > index 80783bb..3f1ff9d 1006

Re: [PATCH 1/2] auxdisplay: charlcd: move charlcd.h to drivers/auxdisplay

2019-08-06 Thread Geert Uytterhoeven
On Tue, Aug 6, 2019 at 9:16 AM Masahiro Yamada wrote: > This header is included in drivers/auxdisplay/. Make it a local header. > > Signed-off-by: Masahiro Yamada Reviewed-by: Geert Uytterhoeven Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux

[PATCH V2 2/3] csky/dma: Fixup cache_op failed when cross memory ZONEs

2019-08-06 Thread guoren
From: Guo Ren If the paddr and size are cross between NORMAL_ZONE and HIGHMEM_ZONE memory range, cache_op will panic in do_page_fault with bad_area. Optimize the code to support the range which cross memory ZONEs. Changes for V2: - Revert back to postcore_initcall Signed-off-by: Guo Ren Cc:

Re: [PATCH RFC] mm/memcontrol: reclaim severe usage over high limit in get_user_pages loop

2019-08-06 Thread Konstantin Khlebnikov
On 8/6/19 10:07 AM, Michal Hocko wrote: On Fri 02-08-19 13:44:38, Michal Hocko wrote: [...] diff --git a/mm/memcontrol.c b/mm/memcontrol.c index ba9138a4a1de..53a35c526e43 100644 --- a/mm/memcontrol.c +++ b/mm/memcontrol.c @@ -2429,8 +2429,12 @@ static int try_charge(struct mem_cgroup *memcg, gf

Re: [PATCH RFC] modpost: Support I2C Aliases from OF tables

2019-08-06 Thread Geert Uytterhoeven
Hi Javier, On Tue, Aug 6, 2019 at 12:25 AM Javier Martinez Canillas wrote: > On 7/31/19 9:44 PM, Wolfram Sang wrote: > > Hi Javier, > >> The other option is to remove i2c_of_match_device() and don't make OF match > >> to fallback to i2c_of_match_device_sysfs(). This is what happens in the > >> A

Re: [RFC PATCH] pciehp: use completion to wait irq_thread 'pciehp_ist'

2019-08-06 Thread Lukas Wunner
On Thu, Jul 04, 2019 at 03:50:38PM +0800, Xiongfeng Wang wrote: > When I use the following command to power on a slot which has been > powered off already. > echo 1 > /sys/bus/pci/slots/22/power > It prints the following error: > -bash: echo: write error: No such device > But the slot is actually p

Re: [PATCH 4.4 00/22] 4.4.188-stable review

2019-08-06 Thread Naresh Kamboju
On Mon, 5 Aug 2019 at 18:34, Greg Kroah-Hartman wrote: > > This is the start of the stable review cycle for the 4.4.188 release. > There are 22 patches in this series, all will be posted as a response > to this one. If anyone has any issues with these being applied, please > let me know. > > Resp

Re: [PATCH v1 2/3] ASoC: rsnd: Allow reconfiguration of clock rate

2019-08-06 Thread Jiada Wang
Hi Morimoto-san Sorry for the delayed response On 2019/07/22 17:41, Kuninori Morimoto wrote: Hi Jiada The solution looks very over-kill to me, especiallyq [3/3] patch is too much to me. 1st, can we start clock at .hw_param, instead of .prepare ? and stop it at .hw_free ? the reasoning to m

[PATCH v5 7/7] perf intel-pt: Add brief documentation for PEBS via Intel PT

2019-08-06 Thread Alexander Shishkin
From: Adrian Hunter Document how to select PEBS via Intel PT and how to display synthesized PEBS samples. Signed-off-by: Adrian Hunter Signed-off-by: Alexander Shishkin --- tools/perf/Documentation/intel-pt.txt | 15 +++ 1 file changed, 15 insertions(+) diff --git a/tools/perf/Do

[PATCH v5 1/7] perf: Allow normal events to output AUX data

2019-08-06 Thread Alexander Shishkin
In some cases, ordinary (non-AUX) events can generate data for AUX events. For example, PEBS events can come out as records in the Intel PT stream instead of their usual DS records, if configured to do so. One requirement for such events is to consistently schedule together, to ensure that the dat

[PATCH v5 3/7] perf tools: Add aux_output attribute flag

2019-08-06 Thread Alexander Shishkin
From: Adrian Hunter Add aux_output attribute flag to match the kernel's perf_event.h file. Signed-off-by: Adrian Hunter Signed-off-by: Alexander Shishkin --- tools/include/uapi/linux/perf_event.h | 3 ++- tools/perf/util/evsel.c | 1 + 2 files changed, 3 insertions(+), 1 deletio

[PATCH v5 2/7] perf/x86/intel: Support PEBS output to PT

2019-08-06 Thread Alexander Shishkin
If PEBS declares ability to output its data to Intel PT stream, use the aux_output attribute bit to enable PEBS data output to PT. This requires a PT event to be present and scheduled in the same context. Unlike the DS area, the kernel does not extract PEBS records from the PT stream to generate co

[PATCH v5 0/7] perf, intel: Add support for PEBS output to Intel PT

2019-08-06 Thread Alexander Shishkin
Hi Peter, Sixth attempt at the PEBS-via-PT feature. The previous ones were [1], [2], [3], [4], [5]. This one addresses the most recent review comments, mainly renaming the new attribute bit and everything related to 'aux_output'. Tooling also changed to use /aux-output/ config term. The PEBS feat

[PATCH v5 4/7] perf tools: Add itrace option 'o' to synthesize aux-output events

2019-08-06 Thread Alexander Shishkin
From: Adrian Hunter Add itrace option 'o' to synthesize events recorded in the AUX area due to the use of perf record's aux-output config term. Signed-off-by: Adrian Hunter Signed-off-by: Alexander Shishkin --- tools/perf/Documentation/itrace.txt | 2 ++ tools/perf/util/auxtrace.c |

[PATCH v5 6/7] perf tools: Add aux-output config term

2019-08-06 Thread Alexander Shishkin
From: Adrian Hunter Expose the aux_output attribute flag to the user to configure, by adding a config term 'aux-output'. For events that support it, selection of 'aux-output' causes the generation of AUX records instead of event records. This requires that an AUX area event is also provided. Sig

Re: [PATCH v4 07/10] regulator: mt6358: Add support for MT6358 regulator

2019-08-06 Thread Hsin-hsiung Wang
Hi Mark, On Mon, 2019-08-05 at 14:10 +0100, Mark Brown wrote: > On Mon, Aug 05, 2019 at 01:21:55PM +0800, Hsin-Hsiung Wang wrote: > > > +static const u32 vmch_voltages[] = { > > + 290, 300, 330, > > +}; > > > +static const u32 vemc_voltages[] = { > > + 290, 300, 330,

[PATCH v5 5/7] perf intel-pt: Process options for PEBS event synthesis

2019-08-06 Thread Alexander Shishkin
From: Adrian Hunter Process synth_opts.other_events and attr.aux_output to set up for synthesizing PEBs via Intel PT events. Signed-off-by: Adrian Hunter Signed-off-by: Alexander Shishkin --- tools/perf/arch/x86/util/intel-pt.c | 23 +++ tools/perf/util/intel-pt.c

Re: [PATCH] iio: adc: max9611: Fix temperature reading in probe

2019-08-06 Thread Jacopo Mondi
Hi Jonathan, On Mon, Aug 05, 2019 at 06:12:44PM +0100, Jonathan Cameron wrote: > On Mon, 5 Aug 2019 17:55:15 +0200 > Jacopo Mondi wrote: > > > The max9611 driver reads the die temperature at probe time to validate > > the communication channel. Use the actual read value to perform the test > > i

Re: [PATCH RFC] modpost: Support I2C Aliases from OF tables

2019-08-06 Thread Geert Uytterhoeven
On Tue, Aug 6, 2019 at 12:48 AM Javier Martinez Canillas wrote: > On 8/1/19 4:17 AM, Masahiro Yamada wrote: > So I think that we should either: > > a) take Kieran's patch or b) remove the i2c_of_match_device_sysfs() fallback > for OF and require an I2C device table for sysfs instantiation and matc

Re: [PATCH v2 3/3] soc/tegra: regulators: Add regulators coupler for Tegra30

2019-08-06 Thread Peter De Schrijver
On Mon, Aug 05, 2019 at 02:03:29PM +0300, Dmitry Osipenko wrote: > 05.08.2019 11:33, Peter De Schrijver пишет: > > On Fri, Aug 02, 2019 at 05:39:23PM +0300, Dmitry Osipenko wrote: > >> 02.08.2019 17:05, Peter De Schrijver пишет: > >>> On Thu, Jul 25, 2019 at 06:18:32PM +0300, Dmitry Osipenko wrote:

[PATCH] arm:unwind: fix backtrace error with unwind_table

2019-08-06 Thread chenzefeng
For arm, when load_module success, the mod->init_layout.base would be free in function do_free_init, but do not remove it's unwind table from the unwind_tables' list. And later the above mod->init_layout.base would alloc for another module's text section, and add to the unwind_tables which cause on

[PATCH net] net: ethernet: sun4i-emac: Support phy-handle property for finding PHYs

2019-08-06 Thread Chen-Yu Tsai
From: Chen-Yu Tsai The sun4i-emac uses the "phy" property to find the PHY it's supposed to use. This property was deprecated in favor of "phy-handle" in commit 8c5b09447625 ("dt-bindings: net: sun4i-emac: Convert the binding to a schemas"). Add support for this new property name, and fall back t

Re: [PATCH RFC] mm/memcontrol: reclaim severe usage over high limit in get_user_pages loop

2019-08-06 Thread Michal Hocko
On Tue 06-08-19 10:19:49, Konstantin Khlebnikov wrote: > On 8/6/19 10:07 AM, Michal Hocko wrote: > > On Fri 02-08-19 13:44:38, Michal Hocko wrote: > > [...] > > > > > diff --git a/mm/memcontrol.c b/mm/memcontrol.c > > > > > index ba9138a4a1de..53a35c526e43 100644 > > > > > --- a/mm/memcontrol.c > >

[PATCH 2/2] habanalabs: improve security in Debug IOCTL

2019-08-06 Thread Omer Shpigelman
This patch improves the security in the Debug IOCTL. It adds checks that: - The register index value is in the allowed range for all opcodes. - The event types number is in the allowed range in SPMU enable. - The events number is in the allowed range in SPMU disable. Signed-off-by: Omer Shpigelman

[PATCH 1/2] habanalabs: use default structure for user input in Debug IOCTL

2019-08-06 Thread Omer Shpigelman
This patch fixes a possible kernel crash when a user provides a too small input structure to the Debug IOCTL. The fix sets a default input structure and copies to it the user data. In case the user provided as input a too small structure, the code will use the default values taken from the default

Re: [PATCH] iio: adc: sc27xx: Change to polling mode to read data

2019-08-06 Thread Baolin Wang
Hi Jonathan, On Mon, 5 Aug 2019 at 21:50, Jonathan Cameron wrote: > > On Mon, 29 Jul 2019 10:19:48 +0800 > Baolin Wang wrote: > > > Hi Jonathan, > > > > On Sun, 28 Jul 2019 at 01:27, Jonathan Cameron wrote: > > > > > > On Thu, 25 Jul 2019 14:33:50 +0800 > > > Baolin Wang wrote: > > > > > > > F

[PATCH] watchdog: jz4740: Fix unused variable warning in jz4740_wdt_probe

2019-08-06 Thread Gustavo A. R. Silva
Fix the following warning (Building: ci20_defconfig mips): drivers/watchdog/jz4740_wdt.c: In function ‘jz4740_wdt_probe’: drivers/watchdog/jz4740_wdt.c:165:6: warning: unused variable ‘ret’ [-Wunused-variable] int ret; ^~~ Fixes: 9ee644c9326c ("watchdog: jz4740_wdt: drop warning after reg

Re: [PATCH v3 4/4] serial: 8250: Don't check for mctrl_gpio_init() returning -ENOSYS

2019-08-06 Thread Uwe Kleine-König
Hey Greg On Fri, Aug 02, 2019 at 02:26:23PM +0200, Greg Kroah-Hartman wrote: > On Fri, Aug 02, 2019 at 02:15:55PM +0200, Uwe Kleine-König wrote: > > On Fri, Aug 02, 2019 at 10:04:11AM +, Schrempf Frieder wrote: > > > From: Frieder Schrempf > > > > > > Now that the mctrl_gpio code returns NUL

Re: [PATCH v3 2/4] serial: mctrl_gpio: Add a NULL check to mctrl_gpio_to_gpiod()

2019-08-06 Thread Uwe Kleine-König
Hello Frieder, On Mon, Aug 05, 2019 at 09:01:39AM +, Schrempf Frieder wrote: > On 02.08.19 14:12, Uwe Kleine-König wrote: > > On Fri, Aug 02, 2019 at 10:04:10AM +, Schrempf Frieder wrote: > >> From: Frieder Schrempf > >> > >> As it is allowed to use the mctrl_gpio_* functions before > >>

[PATCH] ia64:unwind: fix double free for mod->arch.init_unw_table

2019-08-06 Thread chenzefeng
The function free_module in file kernel/module.c as follow: void free_module(struct module *mod) { .. module_arch_cleanup(mod); .. module_arch_freeing_init(mod); .. } Both module_arch_cleanup and module_arch_freeing_init function would free the

[PATCH] i2c: designware: Fix unused variable warning in i2c_dw_init_recovery_info

2019-08-06 Thread Gustavo A. R. Silva
Fix the following warning: drivers/i2c/busses/i2c-designware-master.c: In function ‘i2c_dw_init_recovery_info’: drivers/i2c/busses/i2c-designware-master.c:658:6: warning: unused variable ‘r’ [-Wunused-variable] int r; ^ Fixes: 33eb09a02e8d ("i2c: designware: make use of devm_gpiod_get_o

Re: [PATCH v4 06/10] powerpc/fsl_booke/32: implement KASLR infrastructure

2019-08-06 Thread Christophe Leroy
Le 05/08/2019 à 08:43, Jason Yan a écrit : This patch add support to boot kernel from places other than KERNELBASE. Since CONFIG_RELOCATABLE has already supported, what we need to do is map or copy kernel to a proper place and relocate. Freescale Book-E parts expect lowmem to be mapped by fixe

[PATCH net v2] net: dsa: Check existence of .port_mdb_add callback before calling it

2019-08-06 Thread Chen-Yu Tsai
From: Chen-Yu Tsai With the recent addition of commit 75dad2520fc3 ("net: dsa: b53: Disable all ports on setup"), users of b53 (BCM53125 on Lamobo R1 in my case) are forced to use the dsa subsystem to enable the switch, instead of having it in the default transparent "forward-to-all" mode. The b

Re: [PATCH V2] fork: Improve error message for corrupted page tables

2019-08-06 Thread Vlastimil Babka
On 8/6/19 5:05 AM, Sai Praneeth Prakhya wrote: > When a user process exits, the kernel cleans up the mm_struct of the user > process and during cleanup, check_mm() checks the page tables of the user > process for corruption (E.g: unexpected page flags set/cleared). For > corrupted page tables, th

Re: Bisected: Kernel 4.14 + has 3 times higher write IO latency than Kernel 4.4 with raid1

2019-08-06 Thread Jinpu Wang
On Tue, Aug 6, 2019 at 1:46 AM NeilBrown wrote: > > On Mon, Aug 05 2019, Jinpu Wang wrote: > > > Hi Neil, > > > > For the md higher write IO latency problem, I bisected it to these commits: > > > > 4ad23a97 MD: use per-cpu counter for writes_pending > > 210f7cd percpu-refcount: support synchronous

[PATCH] dt-bindings: arm: amlogic: fix x96-max/sei510 section in amlogic.yaml

2019-08-06 Thread Neil Armstrong
From: Christian Hewitt Move amediatech,x96-max and seirobotics,sei510 to the S905D2 section and update the S905D2 description to S905D2/X2/Y2. Signed-off-by: Christian Hewitt Signed-off-by: Neil Armstrong --- Documentation/devicetree/bindings/arm/amlogic.yaml | 6 +++--- 1 file changed, 3 ins

Re: [PATCH v4 07/10] powerpc/fsl_booke/32: randomize the kernel image offset

2019-08-06 Thread Christophe Leroy
Le 05/08/2019 à 08:43, Jason Yan a écrit : After we have the basic support of relocate the kernel in some appropriate place, we can start to randomize the offset now. Entropy is derived from the banner and timer, which will change every build and boot. This not so much safe so additionally th

Re: [PATCH 1/2] HID: hiddev: avoid opening a disconnected device

2019-08-06 Thread Jiri Kosina
On Tue, 6 Aug 2019, Hillf Danton wrote: > In order to avoid opening a disconnected device, we need to check exist > again after acquiring the existance lock, and bail out if necessary. > > Cc: Andrey Konovalov > Signed-off-by: Hillf Danton Could you please add proper Reported-by: reference to

Re: [PATCH] ia64:unwind: fix double free for mod->arch.init_unw_table

2019-08-06 Thread Greg KH
On Tue, Aug 06, 2019 at 03:46:33PM +0800, chenzefeng wrote: > The function free_module in file kernel/module.c as follow: > > void free_module(struct module *mod) { > .. > module_arch_cleanup(mod); > .. > module_arch_freeing_init(mod); > .. > } > > Both m

Re: [PATCH v4 09/10] powerpc/fsl_booke/kaslr: support nokaslr cmdline parameter

2019-08-06 Thread Christophe Leroy
Le 05/08/2019 à 08:43, Jason Yan a écrit : One may want to disable kaslr when boot, so provide a cmdline parameter 'nokaslr' to support this. Signed-off-by: Jason Yan Cc: Diana Craciun Cc: Michael Ellerman Cc: Christophe Leroy Cc: Benjamin Herrenschmidt Cc: Paul Mackerras Cc: Nicholas P

[PATCH 1/3] mm/migrate: clean up useless code in migrate_vma_collect_pmd()

2019-08-06 Thread Pingfan Liu
Signed-off-by: Pingfan Liu Cc: "Jérôme Glisse" Cc: Andrew Morton Cc: Mel Gorman Cc: Jan Kara Cc: "Kirill A. Shutemov" Cc: Michal Hocko Cc: Mike Kravetz Cc: Andrea Arcangeli Cc: Matthew Wilcox To: linux...@kvack.org Cc: linux-kernel@vger.kernel.org --- mm/migrate.c | 5 + 1 file chang

[PATCH 3/3] mm/migrate: remove the duplicated code migrate_vma_collect_hole()

2019-08-06 Thread Pingfan Liu
After the previous patch which sees hole as invalid source, migrate_vma_collect_hole() has the same code as migrate_vma_collect_skip(). Removing the duplicated code. Signed-off-by: Pingfan Liu Cc: "Jérôme Glisse" Cc: Andrew Morton Cc: Mel Gorman Cc: Jan Kara Cc: "Kirill A. Shutemov" Cc: Mich

[PATCH 2/3] mm/migrate: see hole as invalid source page

2019-08-06 Thread Pingfan Liu
MIGRATE_PFN_MIGRATE marks a valid pfn, further more, suitable to migrate. As for hole, there is no valid pfn, not to mention migration. Before this patch, hole has already relied on the following code to be filtered out. Hence it is more reasonable to see hole as invalid source page. migrate_vma_p

Re: [PATCH V2 05/10] ACPI: cpufreq: Switch to QoS requests instead of cpufreq notifier

2019-08-06 Thread Rafael J. Wysocki
On Tue, Aug 6, 2019 at 6:39 AM Viresh Kumar wrote: > > On 05-08-19, 11:42, Rafael J. Wysocki wrote: > > On Tuesday, July 23, 2019 8:14:05 AM CEST Viresh Kumar wrote: > > > @@ -310,8 +339,11 @@ static int __init acpi_processor_driver_init(void) > > > cpuhp_setup_state_nocalls(CPUHP_ACPI_CPUDRV_

Re: [PATCH v3 2/4] serial: mctrl_gpio: Add a NULL check to mctrl_gpio_to_gpiod()

2019-08-06 Thread Schrempf Frieder
On 06.08.19 09:45, Uwe Kleine-König wrote: > Hello Frieder, > > On Mon, Aug 05, 2019 at 09:01:39AM +, Schrempf Frieder wrote: >> On 02.08.19 14:12, Uwe Kleine-König wrote: >>> On Fri, Aug 02, 2019 at 10:04:10AM +, Schrempf Frieder wrote: From: Frieder Schrempf As it is allo

Re: Question about mfd_add_devices and platform_data

2019-08-06 Thread Lucas Tanure
Hi Lee, Can you help me with this question? Thanks Lucas On Mon, Aug 5, 2019 at 2:43 PM Lucas Tanure wrote: > > Hi, > > I would like to understand mfd_add_devices call and platform_data section. > An mfd device can have platform_data, which is kmemdup at > platform_device_add_data from platform

Re: [PATCH v2 4/4] hugetlbfs: don't retry when pool page allocations start to fail

2019-08-06 Thread Vlastimil Babka
On 8/6/19 3:47 AM, Mike Kravetz wrote: > When allocating hugetlbfs pool pages via /proc/sys/vm/nr_hugepages, > the pages will be interleaved between all nodes of the system. If > nodes are not equal, it is quite possible for one node to fill up > before the others. When this happens, the code sti

Re: [mm] 755d6edc1a: will-it-scale.per_process_ops -4.1% regression

2019-08-06 Thread Michal Hocko
On Tue 06-08-19 15:05:47, kernel test robot wrote: > Greeting, > > FYI, we noticed a -4.1% regression of will-it-scale.per_process_ops due to > commit: I have to confess I cannot make much sense from numbers because they seem to be too volatile and the main contributor doesn't stand up for me. A

[PATCH v8 00/14] Guest LBR Enabling

2019-08-06 Thread Wei Wang
Last Branch Recording (LBR) is a performance monitor unit (PMU) feature on Intel CPUs that captures branch related info. This patch series enables this feature to KVM guests. Each guest can be configured to expose this LBR feature to the guest via userspace setting the enabling param in KVM_CAP_X8

[PATCH v8 01/14] perf/x86: fix the variable type of the lbr msrs

2019-08-06 Thread Wei Wang
The msr variable type can be "unsigned int", which uses less memory than the longer unsigned long. The lbr nr won't be a negative number, so make it "unsigned int" as well. Cc: Peter Zijlstra Cc: Andi Kleen Suggested-by: Peter Zijlstra Signed-off-by: Wei Wang --- arch/x86/events/perf_event.h

[PATCH v8 03/14] KVM/x86: KVM_CAP_X86_GUEST_LBR

2019-08-06 Thread Wei Wang
Introduce KVM_CAP_X86_GUEST_LBR to allow per-VM enabling of the guest lbr feature. Signed-off-by: Wei Wang --- Documentation/virt/kvm/api.txt | 26 ++ arch/x86/include/asm/kvm_host.h | 2 ++ arch/x86/kvm/x86.c | 16 include/uapi/linux/kvm.h

[PATCH v8 02/14] perf/x86: add a function to get the addresses of the lbr stack msrs

2019-08-06 Thread Wei Wang
The lbr stack msrs are model specific. The perf subsystem has already assigned the abstracted msr address values based on the cpu model. So add a function to enable callers outside the perf subsystem to get the lbr stack addresses. This is useful for hypervisors to emulate the lbr feature for the g

[PATCH v8 05/14] KVM/x86/vPMU: tweak kvm_pmu_get_msr

2019-08-06 Thread Wei Wang
Change kvm_pmu_get_msr to get the msr_data struct, as the host_initiated field from the struct could be used by get_msr. This also makes this API consistent with kvm_pmu_set_msr. Cc: Paolo Bonzini Cc: Andi Kleen Signed-off-by: Wei Wang --- arch/x86/kvm/pmu.c | 4 ++-- arch/x86/kvm/p

Re: [PATCH v1 2/3] ASoC: rsnd: Allow reconfiguration of clock rate

2019-08-06 Thread Kuninori Morimoto
Hi Jiada > > 2nd, can we keep usrcnt setup as-is ? > > I guess we can just avoid rsnd_ssi_master_clk_start() if ssi->rate was not > > 0 ? > > I don't fully understand your 2nd question, > in case of rsnd_ssi_master_clk_stop(), if avoid > rsnd_ssi_master_clk_stop() when ssi->rate is 0 by apply

[PATCH v8 04/14] KVM/x86: intel_pmu_lbr_enable

2019-08-06 Thread Wei Wang
The lbr stack is model specific, for example, SKX has 32 lbr stack entries while HSW has 16 entries, so a HSW guest running on a SKX machine may not get accurate perf results. Currently, we forbid the guest lbr enabling when the guest and host see different lbr stack entries or the host and guest s

[PATCH v8 06/14] KVM/x86: expose MSR_IA32_PERF_CAPABILITIES to the guest

2019-08-06 Thread Wei Wang
Bits [0, 5] of MSR_IA32_PERF_CAPABILITIES tell about the format of the addresses stored in the lbr stack. Expose those bits to the guest when the guest lbr feature is enabled. Cc: Paolo Bonzini Cc: Andi Kleen Signed-off-by: Wei Wang --- arch/x86/include/asm/perf_event.h | 2 ++ arch/x86/kvm/c

[PATCH v8 12/14] KVM/x86/lbr: lbr emulation

2019-08-06 Thread Wei Wang
In general, the lbr emulation works in this way: Guest first access (since vcpu scheduled in) to the lbr related msr gets trapped to kvm, and the handler will do the following things: - create an lbr perf event to have the vcpu get the lbr feature from host perf following the perf scheduling

[PATCH v8 14/14] KVM/x86: remove the common handling of the debugctl msr

2019-08-06 Thread Wei Wang
The debugctl msr is not completely identical on AMD and Intel CPUs, for example, FREEZE_LBRS_ON_PMI is supported by Intel CPUs only. Now, this msr is handled separatedly in svm.c and intel_pmu.c. So remove the common debugctl msr handling code in kvm_get/set_msr_common. Cc: Paolo Bonzini Cc: Andi

[PATCH v8 11/14] perf/x86: save/restore LBR_SELECT on vcpu switching

2019-08-06 Thread Wei Wang
The regular host lbr perf event doesn't save/restore the LBR_SELECT msr during a thread context switching, because the LBR_SELECT value is generated from attr.branch_sample_type and already stored in event->hw.branch_reg (please see intel_pmu_setup_hw_filter), which doesn't get lost during thread c

[PATCH v8 13/14] KVM/x86/vPMU: check the lbr feature before entering guest

2019-08-06 Thread Wei Wang
The guest can access the lbr related msrs only when the vcpu's lbr event has been assigned the lbr feature. A cpu pinned lbr event (though no such event usages in the current upstream kernel) could reclaim the lbr feature from the vcpu's lbr event (task pinned) via ipi calls. If the cpu is running

[PATCH v8 09/14] KVM/x86/vPMU: APIs to create/free lbr perf event for a vcpu thread

2019-08-06 Thread Wei Wang
VMX transition is much more frequent than vcpu switching, and saving/restoring tens of lbr msrs (e.g. 32 lbr stack entries) would add too much overhead to the frequent vmx transition, which is not necessary. So the vcpu's lbr state only gets saved/restored on the vcpu context switching. The main p

[PATCH v8 07/14] perf/x86: support to create a perf event without counter allocation

2019-08-06 Thread Wei Wang
Hypervisors may create an lbr event for a vcpu's lbr emulation, and the emulation doesn't need a counter fundamentally. This makes the emulation follow the x86 SDM's description about lbr, which doesn't include a counter, and also avoids wasting a counter. The perf scheduler is supported to not as

[PATCH v8 08/14] perf/core: set the event->owner before event_init

2019-08-06 Thread Wei Wang
Kernel and user events can be distinguished by checking event->owner. Some pmu driver implementation may need to know event->owner in event_init. For example, intel_pmu_setup_lbr_filter treats a kernel event with exclude_host set as an lbr event created for guest lbr emulation, which doesn't need a

[PATCH v8 10/14] perf/x86/lbr: don't share lbr for the vcpu usage case

2019-08-06 Thread Wei Wang
Perf event scheduling lets multiple lbr events share the lbr if they use the same config for LBR_SELECT. For the vcpu case, the vcpu's lbr event created on the host deliberately sets the config to the user callstack mode to have the host support to save/restore the lbr state on vcpu context switchi

Re: [PATCH V3 2/2] cpufreq: intel_pstate: Implement ->resolve_freq()

2019-08-06 Thread Rafael J. Wysocki
On Tue, Aug 6, 2019 at 6:10 AM Viresh Kumar wrote: > > On 02-08-19, 11:28, Rafael J. Wysocki wrote: > > On Friday, August 2, 2019 11:17:55 AM CEST Rafael J. Wysocki wrote: > > > On Fri, Aug 2, 2019 at 7:44 AM Viresh Kumar > > > wrote: > > > > > > > > Intel pstate driver exposes min_perf_pct and

[PATCH v1] drivers/base/memory.c: Fixup documentation of removable/phys_index/block_size_bytes

2019-08-06 Thread David Hildenbrand
Let's rephrase to memory block terminology and add some further clarifications. Cc: Greg Kroah-Hartman Cc: "Rafael J. Wysocki" Cc: Andrew Morton Cc: Michal Hocko Cc: Oscar Salvador Signed-off-by: David Hildenbrand --- drivers/base/memory.c | 11 ++- 1 file changed, 6 insertions(+),

Re: [PATCH v3 4/8] printk: Replace strncmp with str_has_prefix

2019-08-06 Thread Geert Uytterhoeven
Hi Chuhong, On Mon, Aug 5, 2019 at 2:24 PM Chuhong Yuan wrote: > strncmp(str, const, len) is error-prone because len > is easy to have typo. > The example is the hard-coded len has counting error > or sizeof(const) forgets - 1. > So we prefer using newly introduced str_has_prefix() > to substitut

Re: [PATCH v3 1/4] serial: mctrl_gpio: Avoid probe failures in case of missing gpiolib

2019-08-06 Thread Geert Uytterhoeven
On Fri, Aug 2, 2019 at 12:04 PM Schrempf Frieder wrote: > From: Frieder Schrempf > > If CONFIG_GPIOLIB is not enabled, mctrl_gpio_init() and > mctrl_gpio_init_noauto() will currently return an error pointer with > -ENOSYS. As the mctrl GPIOs are usually optional, drivers need to > check for this

Re: [PATCH v3 3/4] serial: sh-sci: Don't check for mctrl_gpio_init() returning -ENOSYS

2019-08-06 Thread Geert Uytterhoeven
On Fri, Aug 2, 2019 at 12:04 PM Schrempf Frieder wrote: > From: Frieder Schrempf > > Now that the mctrl_gpio code returns NULL instead of ERR_PTR(-ENOSYS) > if CONFIG_GPIOLIB is disabled, we can safely remove this check. > > Signed-off-by: Frieder Schrempf Reviewed-by: Geert Uytterhoeven Gr{o

Re: [PATCH 1/2] vfio-mdev/mtty: Simplify interrupt generation

2019-08-06 Thread Cornelia Huck
On Fri, 2 Aug 2019 01:59:04 -0500 Parav Pandit wrote: > While generating interrupt, mdev_state is already available for which > interrupt is generated. > Instead of doing indirect way from state->device->uuid-> to searching > state linearly in linked list on every interrupt generation, > directl

[PATCH] mm/mmap.c: refine data locality of find_vma_prev

2019-08-06 Thread Wei Yang
When addr is out of the range of the whole rb_tree, pprev will points to the biggest node. find_vma_prev gets is by going through the right most node of the tree. Since only the last node is the one it is looking for, it is not necessary to assign pprev to those middle stage nodes. By assigning pp

Re: pivot_root(".", ".") and the fchdir() dance

2019-08-06 Thread Philipp Wendler
Hello Michael, hello Aleksa, Am 05.08.19 um 14:29 schrieb Michael Kerrisk (man-pages): > On 8/5/19 12:36 PM, Aleksa Sarai wrote: >> On 2019-08-01, Michael Kerrisk (man-pages) wrote: >>> I'd like to add some documentation about the pivot_root(".", ".") >>> idea, but I have a doubt/question. In th

Re: [PATCH v2 1/4] clk: core: introduce clk_hw_set_parent()

2019-08-06 Thread Jerome Brunet
On Wed 31 Jul 2019 at 10:40, Neil Armstrong wrote: > Introduce the clk_hw_set_parent() provider call to change parent of > a clock by using the clk_hw pointers. > > This eases the clock reparenting from clock rate notifiers and > implementing DVFS with simpler code avoiding the boilerplates > fun

Re: [PATCH 2/2] vfio/mdev: Removed unused and redundant API for mdev name

2019-08-06 Thread Cornelia Huck
On Fri, 2 Aug 2019 01:59:05 -0500 Parav Pandit wrote: > There is no single production driver who is interested in mdev device > name. > Additionally mdev device name is already available using core kernel > API dev_name(). The patch description is a bit confusing: You talk about removing an api

Re: kernel BUG at mm/vmscan.c:LINE! (2)

2019-08-06 Thread Michal Hocko
On Sat 03-08-19 05:06:43, Minchan Kim wrote: > On Fri, Aug 02, 2019 at 10:58:05AM -0700, syzbot wrote: > > Hello, > > > > syzbot found the following crash on: > > > > HEAD commit:0d8b3265 Add linux-next specific files for 20190729 > > git tree: linux-next > > console output: https://syz

[PATCH] scsi: fas216: Mark expected switch fall-throughs

2019-08-06 Thread Gustavo A. R. Silva
Mark switch cases where we are expecting to fall through. Fix the following warnings (Building: rpc_defconfig arm): drivers/scsi/arm/fas216.c: In function ‘fas216_disconnect_intr’: drivers/scsi/arm/fas216.c:913:6: warning: this statement may fall through [-Wimplicit-fallthrough=] if (fas216_g

Re: [PATCH v9 04/11] x86/entry/64: Adapt assembly for PIE support

2019-08-06 Thread Peter Zijlstra
On Tue, Aug 06, 2019 at 07:08:51AM +0200, Borislav Petkov wrote: > On Mon, Aug 05, 2019 at 10:50:30AM -0700, Thomas Garnier wrote: > > I saw that %rdx was used for temporary usage and restored before the > > end so I assumed that it was not an option. > > PUSH_AND_CLEAR_REGS saves all regs earlier

Re: [PATCH V2] fork: Improve error message for corrupted page tables

2019-08-06 Thread Anshuman Khandual
On 08/06/2019 01:23 PM, Vlastimil Babka wrote: > > On 8/6/19 5:05 AM, Sai Praneeth Prakhya wrote: >> When a user process exits, the kernel cleans up the mm_struct of the user >> process and during cleanup, check_mm() checks the page tables of the user >> process for corruption (E.g: unexpected

[PATCH] ata: rb532_cf: Fix unused variable warning in rb532_pata_driver_probe

2019-08-06 Thread Gustavo A. R. Silva
Fix the following warning (Building: rb532_defconfig mips): drivers/ata/pata_rb532_cf.c: In function ‘rb532_pata_driver_remove’: drivers/ata/pata_rb532_cf.c:161:24: warning: unused variable ‘info’ [-Wunused-variable] struct rb532_cf_info *info = ah->private_data; ^~~~ F

  1   2   3   4   5   6   7   8   9   10   >