Re: [PATCH v5 1/5] mm: add vm_insert_mixed_mkwrite()

2017-07-24 Thread Kirill A. Shutemov
On Mon, Jul 24, 2017 at 11:06:12AM -0600, Ross Zwisler wrote: > @@ -1658,14 +1658,35 @@ static int insert_pfn(struct vm_area_struct *vma, > unsigned long addr, > if (!pte) > goto out; > retval = -EBUSY; > - if (!pte_none(*pte)) > - goto out_unlock; > +

Re: [PATCH] kthread: Fix documentation build warning

2017-07-24 Thread Jonathan Corbet
On Mon, 24 Jul 2017 14:24:44 -0700 Randy Dunlap wrote: > > + * @arg...: arguments for @namefmt. > > * > > Hm, Documentation/doc-guide/kernel-doc.rst says: > If a function parameter is ``...`` (varargs), it should be listed > in kernel-doc notation as: ``@...:``. > > but the patch here is fo

Re: [PATCH] kthread: Fix documentation build warning

2017-07-24 Thread Randy Dunlap
On 07/24/2017 12:59 PM, Jonathan Corbet wrote: > The kerneldoc comment for kthread_create() had an incorrect argument name, > leading to a warning in the docs build. Correct it, and make one more > small step toward a warning-free build. > > Signed-off-by: Jonathan Corbet > --- > include/linux/

Re: [PATCH 00/13] net: dsa: lan9303: unicast offload, fdb,mdb,STP

2017-07-24 Thread David Miller
From: Egil Hjelmeland Date: Mon, 24 Jul 2017 16:47:51 +0200 > This is my first patches submitted to the kernel, so I am looking > forward to comments. Please clean up how the dates are handled in your submission. They are all over the place, over a period of 3 days. Instead, they should be con

[PATCH] kthread: Fix documentation build warning

2017-07-24 Thread Jonathan Corbet
The kerneldoc comment for kthread_create() had an incorrect argument name, leading to a warning in the docs build. Correct it, and make one more small step toward a warning-free build. Signed-off-by: Jonathan Corbet --- include/linux/kthread.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(

[PATCH] sched/wait: Clean up some documentation warnings

2017-07-24 Thread Jonathan Corbet
A couple of kerneldoc comments in had incorrect names for macro parameters, with this unsightly result: ./include/linux/wait.h:555: warning: No description found for parameter 'wq' ./include/linux/wait.h:555: warning: Excess function parameter 'wq_head' description in 'wait_event_interruptib

[PATCH] sched/core: Fix some documentation build warnings

2017-07-24 Thread Jonathan Corbet
The kerneldoc comments for try_to_wake_up_local() were out of date, leading to these documentation build warnings: ./kernel/sched/core.c:2080: warning: No description found for parameter 'rf' ./kernel/sched/core.c:2080: warning: Excess function parameter 'cookie' description in 'try_to_wake_u

[PATCH] mod_devicetable.h: Fix docs build warnings

2017-07-24 Thread Jonathan Corbet
Commit 0afef45654ae908536278ecb143ded5bbc713391 (staging: fsl-mc: add support for device table matching) added kerneldoc comments for two nonexistent structure fields, leading to these warnings in the docs build: ./include/linux/mod_devicetable.h:687: warning: Excess struct/union/enum/typedef m

[PATCH v5 1/5] mm: add vm_insert_mixed_mkwrite()

2017-07-24 Thread Ross Zwisler
To be able to use the common 4k zero page in DAX we need to have our PTE fault path look more like our PMD fault path where a PTE entry can be marked as dirty and writeable as it is first inserted rather than waiting for a follow-up dax_pfn_mkwrite() => finish_mkwrite_fault() call. Right now we ca

[PATCH v5 4/5] dax: remove DAX code from page_cache_tree_insert()

2017-07-24 Thread Ross Zwisler
Now that we no longer insert struct page pointers in DAX radix trees we can remove the special casing for DAX in page_cache_tree_insert(). This also allows us to make dax_wake_mapping_entry_waiter() local to fs/dax.c, removing it from dax.h. Signed-off-by: Ross Zwisler Suggested-by: Jan Kara Re

[PATCH v5 5/5] dax: move all DAX radix tree defs to fs/dax.c

2017-07-24 Thread Ross Zwisler
Now that we no longer insert struct page pointers in DAX radix trees the page cache code no longer needs to know anything about DAX exceptional entries. Move all the DAX exceptional entry definitions from dax.h to fs/dax.c. Signed-off-by: Ross Zwisler Suggested-by: Jan Kara Reviewed-by: Jan Kar

[PATCH v5 3/5] dax: use common 4k zero page for dax mmap reads

2017-07-24 Thread Ross Zwisler
When servicing mmap() reads from file holes the current DAX code allocates a page cache page of all zeroes and places the struct page pointer in the mapping->page_tree radix tree. This has three major drawbacks: 1) It consumes memory unnecessarily. For every 4k page that is read via a DAX mmap()

[PATCH v5 2/5] dax: relocate some dax functions

2017-07-24 Thread Ross Zwisler
dax_load_hole() will soon need to call dax_insert_mapping_entry(), so it needs to be moved lower in dax.c so the definition exists. dax_wake_mapping_entry_waiter() will soon be removed from dax.h and be made static to dax.c, so we need to move its definition above all its callers. Signed-off-by:

[PATCH v5 0/5] DAX common 4k zero page

2017-07-24 Thread Ross Zwisler
Changes since v4: - Added static __vm_insert_mixed() to mm/memory.c that holds the common code for both vm_insert_mixed() and vm_insert_mixed_mkwrite() so we don't have duplicate code and we don't have to pass boolean flags around. (Dan & Jan) - Added a comment for the PFN sanity check

Re: [PATCH 13/13] net: dsa: lan9303: lan9303_port_mdb_del remove port 0

2017-07-24 Thread Florian Fainelli
On 07/20/2017 06:57 AM, Egil Hjelmeland wrote: > Workaround for dsa_switch_mdb_add adding CPU port to group, > but forgetting to remove it: > > Remove port 0 if only port 0 is only port left. > > Signed-off-by: Egil Hjelmeland > --- > drivers/net/dsa/lan9303-core.c | 11 +++ > 1 file ch

Re: [PATCH 12/13] net: dsa: lan9303: Added "stp_enable" sysfs attribute

2017-07-24 Thread Florian Fainelli
On 07/20/2017 06:42 AM, Egil Hjelmeland wrote: > Must be set to 1 by user space when STP is used on the lan9303. > If bridging without local STP, leave at 0, so external STP BPDUs > are forwarded. > > Hopefully the kernel can be improved so the driver can handle this > without user intervention, a

Re: [PATCH 00/13] net: dsa: lan9303: unicast offload, fdb,mdb,STP

2017-07-24 Thread Florian Fainelli
Hi, On 07/24/2017 07:47 AM, Egil Hjelmeland wrote: > This series extends the LAN9303 3 port switch DSA driver. Highlights: > - Make the MDIO interface work > - Bridging: Unicast offload > - Bridging: Added fdb/mdb handling > - Bridging: STP support > - Documentation > > The last three patche

Re: [PATCH 10/13] net: dsa: lan9303: Only allocate 3 ports

2017-07-24 Thread Florian Fainelli
On 07/20/2017 03:35 AM, Egil Hjelmeland wrote: > Saving 2628 bytes. > > Signed-off-by: Egil Hjelmeland Reviewed-by: Florian Fainelli -- Florian -- To unsubscribe from this list: send the line "unsubscribe linux-doc" in the body of a message to majord...@vger.kernel.org More majordomo info at

Re: [PATCH 11/13] net: dsa: lan9303: Added "alr_dump" sysfs port attribute

2017-07-24 Thread Florian Fainelli
On 07/20/2017 01:49 AM, Egil Hjelmeland wrote: > Added read only file /sys/class/net//lan9303/alr_dump, > that output 168 first ALR entires. > > Currently "bridge fdb show" does not include the CPU port, while > "alr_dump" list all three ports per entry. Agreed, and this is a limitation we would

Re: [PATCH v4 1/5] mm: add mkwrite param to vm_insert_mixed()

2017-07-24 Thread Jan Kara
On Mon 24-07-17 09:23:57, Ross Zwisler wrote: > On Mon, Jul 24, 2017 at 01:25:30PM +0200, Jan Kara wrote: > > > @@ -1658,14 +1658,28 @@ static int insert_pfn(struct vm_area_struct *vma, > > > unsigned long addr, > > > if (!pte) > > > goto out; > > > retval = -EBUSY; > > > - if (!pte_

Re: [PATCH v2 3/4] fs/dcache: Enable automatic pruning of negative dentries

2017-07-24 Thread Waiman Long
On 07/21/2017 07:07 PM, James Bottomley wrote: > On Fri, 2017-07-21 at 16:17 -0400, Waiman Long wrote: >> On 07/21/2017 03:30 PM, James Bottomley wrote: >>> On Fri, 2017-07-21 at 09:43 -0400, Waiman Long wrote: Having a limit for the number of negative dentries does have an undesirable si

[PATCH 04/13] net: dsa: lan9303: Added adjust_link() method

2017-07-24 Thread Egil Hjelmeland
This makes the driver react to device tree "fixed-link" declaration on CPU port. - turn off autonegotiation - force speed 10 or 100 mb/s - force duplex mode Signed-off-by: Egil Hjelmeland --- drivers/net/dsa/lan9303-core.c | 33 + 1 file changed, 33 insertions(+)

[PATCH 08/13] net: dsa: lan9303: Added ALR/fdb/mdb handling

2017-07-24 Thread Egil Hjelmeland
Added functions for accessing / managing the lan9303 ALR (Address Logic Resolution). Implemented DSA methods: set_addr, port_fast_age, port_fdb_prepare, port_fdb_add, port_fdb_del, port_fdb_dump, port_mdb_prepare, port_mdb_add and port_mdb_del. Since the lan9303 do not offer reading specific ALR

[PATCH 02/13] net: dsa: lan9303: Do not disable/enable switch fabric port 0 at startup

2017-07-24 Thread Egil Hjelmeland
For some mysterious reason enable switch fabric port 0 TX fails to work, when the TX has previous been disabled. Resolved by not disable/enable switch fabric port 0 at startup. Port 1 and 2 are still disabled in early init. Signed-off-by: Egil Hjelmeland --- drivers/net/dsa/lan9303-core.c | 7 --

[PATCH 13/13] net: dsa: lan9303: lan9303_port_mdb_del remove port 0

2017-07-24 Thread Egil Hjelmeland
Workaround for dsa_switch_mdb_add adding CPU port to group, but forgetting to remove it: Remove port 0 if only port 0 is only port left. Signed-off-by: Egil Hjelmeland --- drivers/net/dsa/lan9303-core.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/drivers/net/dsa/lan9303-cor

[PATCH 12/13] net: dsa: lan9303: Added "stp_enable" sysfs attribute

2017-07-24 Thread Egil Hjelmeland
Must be set to 1 by user space when STP is used on the lan9303. If bridging without local STP, leave at 0, so external STP BPDUs are forwarded. Hopefully the kernel can be improved so the driver can handle this without user intervention, and this control can be removed. Signed-off-by: Egil Hjelme

[PATCH 11/13] net: dsa: lan9303: Added "alr_dump" sysfs port attribute

2017-07-24 Thread Egil Hjelmeland
Added read only file /sys/class/net//lan9303/alr_dump, that output 168 first ALR entires. Currently "bridge fdb show" does not include the CPU port, while "alr_dump" list all three ports per entry. Example output: 9c:57:ad:79:d0:84 1 l 01:80:c2:00:00:00 0 s 00:13:cb:0d:01:95 0 s 10:f3:11:f

[PATCH 10/13] net: dsa: lan9303: Only allocate 3 ports

2017-07-24 Thread Egil Hjelmeland
Saving 2628 bytes. Signed-off-by: Egil Hjelmeland --- drivers/net/dsa/lan9303-core.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/net/dsa/lan9303-core.c b/drivers/net/dsa/lan9303-core.c index dc95973d62ed..ad7a4c72e1fb 100644 --- a/drivers/net/dsa/lan9303-core.c

[PATCH 09/13] net: dsa: lan9303: Added Documentation/networking/dsa/lan9303.txt

2017-07-24 Thread Egil Hjelmeland
Signed-off-by: Egil Hjelmeland --- Documentation/networking/dsa/lan9303.txt | 48 1 file changed, 48 insertions(+) create mode 100644 Documentation/networking/dsa/lan9303.txt diff --git a/Documentation/networking/dsa/lan9303.txt b/Documentation/networking/dsa/l

[PATCH 03/13] net: dsa: lan9303: Refactor lan9303_enable_packet_processing()

2017-07-24 Thread Egil Hjelmeland
lan9303_enable_packet_processing, lan9303_disable_packet_processing() Pass port number (0,1,2) as parameter instead of port offset. Simplify accordingly. Signed-off-by: Egil Hjelmeland --- drivers/net/dsa/lan9303-core.c | 66 -- 1 file changed, 32 insertio

[PATCH 07/13] net: dsa: lan9303: Added basic offloading of unicast traffic

2017-07-24 Thread Egil Hjelmeland
When both user ports are joined to the same bridge, the normal HW MAC learning is enabled. This means that unicast traffic is forwarded in HW. Support for STP is also added. If one of the user ports leave the bridge, the ports goes back to the initial separated operation. Added brigde methods por

[PATCH 06/13] net: dsa: lan9303: added sysfs node swe_bcst_throt

2017-07-24 Thread Egil Hjelmeland
Allowing per-port access to Switch Engine Broadcast Throttling Register Also added lan9303_write_switch_reg_mask() Signed-off-by: Egil Hjelmeland --- drivers/net/dsa/lan9303-core.c | 83 ++ 1 file changed, 83 insertions(+) diff --git a/drivers/net/dsa/la

[PATCH 05/13] net: dsa: added dsa_net_device_to_dsa_port()

2017-07-24 Thread Egil Hjelmeland
Allowing dsa drivers to attach sysfs nodes. Signed-off-by: Egil Hjelmeland --- include/net/dsa.h | 1 + net/dsa/slave.c | 10 ++ 2 files changed, 11 insertions(+) diff --git a/include/net/dsa.h b/include/net/dsa.h index 88da272d20d0..a71c0a2401ee 100644 --- a/include/net/dsa.h +++ b/

[PATCH 01/13] net: dsa: lan9303: Fixed MDIO interface

2017-07-24 Thread Egil Hjelmeland
Fixes after testing on actual HW: - lan9303_mdio_write()/_read() must multiply register number by 4 to get offset - Indirect access (PMI) to phy register only work in I2C mode. In MDIO mode phy registers must be accessed directly. Introduced struct lan9303_phy_ops to handle the two modes. R

[PATCH 00/13] net: dsa: lan9303: unicast offload, fdb,mdb,STP

2017-07-24 Thread Egil Hjelmeland
This series extends the LAN9303 3 port switch DSA driver. Highlights: - Make the MDIO interface work - Bridging: Unicast offload - Bridging: Added fdb/mdb handling - Bridging: STP support - Documentation The last three patches are workarounds due to current kernel limitations. This is my fir

[PATCH] kbuild: Update example for ccflags-y usage

2017-07-24 Thread Sedat Dilek
From: Sedat Dilek The old example to describe ccflags-y usage is no more valid. Signed-off-by: Sedat Dilek --- Documentation/kbuild/makefiles.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Documentation/kbuild/makefiles.txt b/Documentation/kbuild/makefiles.txt i

Re: [PATCH v4 1/5] mm: add mkwrite param to vm_insert_mixed()

2017-07-24 Thread Ross Zwisler
On Mon, Jul 24, 2017 at 01:25:30PM +0200, Jan Kara wrote: > > @@ -1658,14 +1658,28 @@ static int insert_pfn(struct vm_area_struct *vma, > > unsigned long addr, > > if (!pte) > > goto out; > > retval = -EBUSY; > > - if (!pte_none(*pte)) > > - goto out_unlock; > > +

Re: [PATCH v4 1/5] mm: add mkwrite param to vm_insert_mixed()

2017-07-24 Thread Ross Zwisler
On Mon, Jul 24, 2017 at 01:15:31PM +0200, Jan Kara wrote: > On Sat 22-07-17 09:21:31, Dan Williams wrote: > > On Fri, Jul 21, 2017 at 3:39 PM, Ross Zwisler > > wrote: > > > To be able to use the common 4k zero page in DAX we need to have our PTE > > > fault path look more like our PMD fault path w

Re: [PATCH v2] kmemleak: add oom= runtime parameter

2017-07-24 Thread Catalin Marinas
On Mon, Jul 24, 2017 at 05:16:34PM +0800, shuw...@redhat.com wrote: > When running memory stress tests, kmemleak could be easily disabled in > function create_object as system is out of memory and kmemleak failed to > alloc from object_cache. Since there's no way to enable kmemleak after > it's off

[PATCH] pkeys: fix macro typo in protection-keys.txt

2017-07-24 Thread Wang Kai
Replace PKEY_DENY_WRITE with PKEY_DISABLE_WRITE, which correspond with source code. Signed-off-by: Wang Kai --- Documentation/x86/protection-keys.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Documentation/x86/protection-keys.txt b/Documentation/x86/protection-ke

Re: [PATCH v2 0/8] Add a script to check for Sphinx install requirements

2017-07-24 Thread Mauro Carvalho Chehab
Em Sun, 23 Jul 2017 20:01:44 -0300 Mauro Carvalho Chehab escreveu: > Em Sun, 23 Jul 2017 16:08:29 -0600 > Jonathan Corbet escreveu: > > > On Mon, 17 Jul 2017 18:46:34 -0300 > > Mauro Carvalho Chehab wrote: > > > > > Sphinx installation is not trivial, as not all versions are supported, > >

[PATCH] scripts/sphinx-pre-install: add minimum support for RHEL

2017-07-24 Thread Mauro Carvalho Chehab
RHEL 7.x and clone distros are shipped with Sphinx 1.1.x, with is incompatible with Kernel ReST markups. So, on those systems, the only alternative is to install it via a Python virtual environment. While seeking for "pip" on CentOS 7.3, I noticed that it is not really needed, as python-virtualen

Re: [PATCH v4 5/5] dax: move all DAX radix tree defs to fs/dax.c

2017-07-24 Thread Jan Kara
On Fri 21-07-17 16:39:55, Ross Zwisler wrote: > Now that we no longer insert struct page pointers in DAX radix trees the > page cache code no longer needs to know anything about DAX exceptional > entries. Move all the DAX exceptional entry definitions from dax.h to > fs/dax.c. > > Signed-off-by:

Re: [PATCH v4 4/5] dax: remove DAX code from page_cache_tree_insert()

2017-07-24 Thread Jan Kara
On Fri 21-07-17 16:39:54, Ross Zwisler wrote: > Now that we no longer insert struct page pointers in DAX radix trees we can > remove the special casing for DAX in page_cache_tree_insert(). This also > allows us to make dax_wake_mapping_entry_waiter() local to fs/dax.c, > removing it from dax.h. >

Re: [PATCH v4 3/5] dax: use common 4k zero page for dax mmap reads

2017-07-24 Thread Jan Kara
On Fri 21-07-17 16:39:53, Ross Zwisler wrote: > When servicing mmap() reads from file holes the current DAX code allocates > a page cache page of all zeroes and places the struct page pointer in the > mapping->page_tree radix tree. This has three major drawbacks: > > 1) It consumes memory unneces

Re: [PATCH v4 2/5] dax: relocate some dax functions

2017-07-24 Thread Jan Kara
On Fri 21-07-17 16:39:52, Ross Zwisler wrote: > dax_load_hole() will soon need to call dax_insert_mapping_entry(), so it > needs to be moved lower in dax.c so the definition exists. > > dax_wake_mapping_entry_waiter() will soon be removed from dax.h and be made > static to dax.c, so we need to mov

Re: [PATCH v8 00/20] ILP32 for ARM64

2017-07-24 Thread Yury Norov
pinion > every 6 months. It's just that I will revisit periodically the progress > on automated testing, public availability of a cross-toolchain, > Tested/Acked/Reviewed-by tags on these patches from interested parties. > Since I haven't seen any of these now, I don't see an

Re: [PATCH v4 1/5] mm: add mkwrite param to vm_insert_mixed()

2017-07-24 Thread Jan Kara
> @@ -1658,14 +1658,28 @@ static int insert_pfn(struct vm_area_struct *vma, > unsigned long addr, > if (!pte) > goto out; > retval = -EBUSY; > - if (!pte_none(*pte)) > - goto out_unlock; > + if (!pte_none(*pte)) { > + if (mkwrite) { > +

Re: [PATCH v3 1/5] mm: add vm_insert_mixed_mkwrite()

2017-07-24 Thread Jan Kara
On Fri 21-07-17 11:44:05, Ross Zwisler wrote: > On Wed, Jul 19, 2017 at 03:58:31PM -0600, Ross Zwisler wrote: > > On Wed, Jul 19, 2017 at 11:51:12AM -0600, Ross Zwisler wrote: > > > On Wed, Jul 19, 2017 at 04:16:59PM +0200, Jan Kara wrote: > > > > On Wed 28-06-17 16:01:48, Ross Zwisler wrote: > > >

Re: [PATCH v4 1/5] mm: add mkwrite param to vm_insert_mixed()

2017-07-24 Thread Jan Kara
On Sat 22-07-17 09:21:31, Dan Williams wrote: > On Fri, Jul 21, 2017 at 3:39 PM, Ross Zwisler > wrote: > > To be able to use the common 4k zero page in DAX we need to have our PTE > > fault path look more like our PMD fault path where a PTE entry can be > > marked as dirty and writeable as it is f

Re: [PATCH] documentation: Fix two-CPU control-dependency example

2017-07-24 Thread Akira Yokosawa
On 2017/07/24 14:34:07 +0800, Boqun Feng wrote: > On Mon, Jul 24, 2017 at 09:04:57AM +0900, Akira Yokosawa wrote: > [...] >>> >>> ->8 >>> Subject: [PATCH] kernel: Emphasize the return value of READ_ONCE() is >>> honored >>> >>> READ_ONCE() is used around in kernel to provide a cont

[PATCH v2] kmemleak: add oom= runtime parameter

2017-07-24 Thread shuwang
From: Shu Wang When running memory stress tests, kmemleak could be easily disabled in function create_object as system is out of memory and kmemleak failed to alloc from object_cache. Since there's no way to enable kmemleak after it's off, simply ignore the object_cache alloc failure will just lo

[PATCH] docs: driver-api: Remove trailing blank line

2017-07-24 Thread Thierry Reding
From: Thierry Reding There's no use for this blank line at the end of the file. Remove it. Signed-off-by: Thierry Reding --- Documentation/driver-api/miscellaneous.rst | 1 - 1 file changed, 1 deletion(-) diff --git a/Documentation/driver-api/miscellaneous.rst b/Documentation/driver-api/misc

Re: [RFC PATCH 0/4] Documentation: generated module param documentation

2017-07-24 Thread Jani Nikula
On Mon, 24 Jul 2017, Jonathan Corbet wrote: > On Wed, 19 Jul 2017 16:05:01 +0300 > Jani Nikula wrote: > >> Hi Jon, all, here are some quick'n'dirty patches to semi-automatically >> generate module param documentation from the source, via module build >> and modinfo(8). No polish or proper design,

Re: [PATCH 1/3] irq/irq_sim: add a simple interrupt simulator framework

2017-07-24 Thread Lars-Peter Clausen
On 07/19/2017 02:20 PM, Bartosz Golaszewski wrote: [...] > +void irq_sim_fini(struct irq_sim *sim) > +{ Not very likely to happen in practice, but for correctness we should probably put a irq_work_sync() here for each of the IRQs to make sure that the memory associated with the irq_sim_work_ctx st