24 Aug, 2018

4 commits

  • Link: http://lkml.kernel.org/r/1532626360-16650-8-git-send-email-rppt@linux.vnet.ibm.com
    Signed-off-by: Mike Rapoport
    Reviewed-by: Andrew Morton
    Cc: Jonathan Corbet
    Cc: Matthew Wilcox
    Cc: Michal Hocko
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Mike Rapoport
     
  • This is basically copy-paste of the memory management section from
    kernel-api.rst with some minor adjustments:

    * The "User Space Memory Access" is moved to the beginning
    * The get_user_pages_fast reference is now a part of "User Space Memory
    Access"
    * And, of course, headings are adjusted with section being promoted to
    chapters

    Link: http://lkml.kernel.org/r/1532626360-16650-6-git-send-email-rppt@linux.vnet.ibm.com
    Signed-off-by: Mike Rapoport
    Reviewed-by: Andrew Morton
    Cc: Jonathan Corbet
    Cc: Matthew Wilcox
    Cc: Michal Hocko
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Mike Rapoport
     
  • The string and memory duplication routines fit better to the "String
    Manipulation" section than to "The SLAB Cache".

    Link: http://lkml.kernel.org/r/1532626360-16650-5-git-send-email-rppt@linux.vnet.ibm.com
    Signed-off-by: Mike Rapoport
    Reviewed-by: Andrew Morton
    Cc: Jonathan Corbet
    Cc: Matthew Wilcox
    Cc: Michal Hocko
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Mike Rapoport
     
  • Link: http://lkml.kernel.org/r/1532626360-16650-4-git-send-email-rppt@linux.vnet.ibm.com
    Signed-off-by: Mike Rapoport
    Reviewed-by: Andrew Morton
    Cc: Jonathan Corbet
    Cc: Matthew Wilcox
    Cc: Michal Hocko
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Mike Rapoport
     

15 Aug, 2018

1 commit

  • Pull documentation update from Jonathan Corbet:
    "This was a moderately busy cycle for docs, with the usual collection
    of small fixes and updates.

    We also have new ktime_get_*() docs from Arnd, some kernel-doc fixes,
    a new set of Italian translations (non so se vale la pena, ma non fa
    male - speriamo bene), and some extensive early memory-management
    documentation improvements from Mike Rapoport"

    * tag 'docs-4.19' of git://git.lwn.net/linux: (52 commits)
    Documentation: corrections to console/console.txt
    Documentation: add ioctl number entry for v4l2-subdev.h
    Remove gendered language from management style documentation
    scripts/kernel-doc: Escape all literal braces in regexes
    docs/mm: add description of boot time memory management
    docs/mm: memblock: add overview documentation
    docs/mm: memblock: add kernel-doc description for memblock types
    docs/mm: memblock: add kernel-doc comments for memblock_add[_node]
    docs/mm: memblock: update kernel-doc comments
    mm/memblock: add a name for memblock flags enumeration
    docs/mm: bootmem: add overview documentation
    docs/mm: bootmem: add kernel-doc description of 'struct bootmem_data'
    docs/mm: bootmem: fix kernel-doc warnings
    docs/mm: nobootmem: fixup kernel-doc comments
    mm/bootmem: drop duplicated kernel-doc comments
    Documentation: vm.txt: Adding 'nr_hugepages_mempolicy' parameter description.
    doc:it_IT: translation for kernel-hacking
    docs: Fix the reference labels in Locking.rst
    doc: tracing: Fix a typo of trace_stat
    mm: Introduce new type vm_fault_t
    ...

    Linus Torvalds
     

03 Aug, 2018

2 commits


23 Jul, 2018

1 commit

  • As Dave Chinner points out, we don't have a proper documentation for the
    ktime_get() family of interfaces, making it rather unclear which of the
    over 30 (!) interfaces one should actually use in a driver or elsewhere
    in the kernel.

    I wrote up an explanation from how I personally see the interfaces,
    documenting what each of the functions do and hopefully making it a bit
    clearer which should be used where.

    This is the first time I tried writing .rst format documentation, so
    in addition to any mistakes in the content, I probably also introduce
    nonstandard formatting ;-)

    I first tried to add an extra section to
    Documentation/timers/timekeeping.txt, but this is currently not included
    in the generated API, and it seems useful to have the API docs as part
    of what gets generated in
    https://www.kernel.org/doc/html/latest/core-api/index.html#core-utilities
    instead, so I started a new file there.

    I also considered adding the documentation inline in the
    include/linux/timekeeping.h header, but couldn't figure out how to do
    that in a way that would result both in helpful inline comments as
    well as readable html output, so I settled for the latter, with
    a small note pointing to it from the header.

    Cc: Dave Chinner
    Cc: John Stultz
    Cc: Thomas Gleixner
    Cc: Stephen Boyd
    Tested-by: Randy Dunlap
    Reviewed-by: Randy Dunlap
    Reviewed-by: Linus Walleij
    Signed-off-by: Arnd Bergmann
    Signed-off-by: Jonathan Corbet

    Arnd Bergmann
     

17 Jul, 2018

1 commit

  • The atomic_set() and ATOMIC_INIT() operations are writes, so this
    commit changes their description from "reads" to "writes".

    Signed-off-by: Jonathan Neuschäfer
    Signed-off-by: Paul E. McKenney
    Reviewed-by: Andrea Parri
    Cc: Linus Torvalds
    Cc: Peter Zijlstra
    Cc: Thomas Gleixner
    Cc: akiyks@gmail.com
    Cc: boqun.feng@gmail.com
    Cc: dhowells@redhat.com
    Cc: j.alglave@ucl.ac.uk
    Cc: linux-arch@vger.kernel.org
    Cc: luc.maranget@inria.fr
    Cc: npiggin@gmail.com
    Cc: parri.andrea@gmail.com
    Cc: stern@rowland.harvard.edu
    Cc: will.deacon@arm.com
    Link: http://lkml.kernel.org/r/20180716180605.16115-8-paulmck@linux.vnet.ibm.com
    Signed-off-by: Ingo Molnar

    Jonathan Neuschäfer
     

03 Jul, 2018

1 commit


30 Jun, 2018

1 commit


18 Jun, 2018

1 commit


07 Jun, 2018

1 commit

  • Pull printk updates from Petr Mladek:

    - Help userspace log daemons to catch up with a flood of messages. They
    will get woken after each message even if the console is far behind
    and handled by another process.

    - Flush printk safe buffers safely even when panic() happens in the
    normal context.

    - Fix possible va_list reuse when race happened in printk_safe().

    - Remove %pCr printf format to prevent sleeping in the atomic context.

    - Misc vsprintf code cleanup.

    * tag 'printk-for-4.18' of git://git.kernel.org/pub/scm/linux/kernel/git/pmladek/printk:
    printk: drop in_nmi check from printk_safe_flush_on_panic()
    lib/vsprintf: Remove atomic-unsafe support for %pCr
    serial: sh-sci: Stop using printk format %pCr
    thermal: bcm2835: Stop using printk format %pCr
    clk: renesas: cpg-mssr: Stop using printk format %pCr
    printk: fix possible reuse of va_list variable
    printk: wake up klogd in vprintk_emit
    vsprintf: Tweak pF/pf comment
    lib/vsprintf: Mark expected switch fall-through
    lib/vsprintf: Replace space with '_' before crng is ready
    lib/vsprintf: Deduplicate pointer_string()
    lib/vsprintf: Move pointer_string() upper
    lib/vsprintf: Make flag_spec global
    lib/vsprintf: Make strspec global
    lib/vsprintf: Make dec_spec global
    lib/test_printf: Mark big constant with UL

    Linus Torvalds
     

05 Jun, 2018

2 commits

  • "%pCr" formats the current rate of a clock, and calls clk_get_rate().
    The latter obtains a mutex, hence it must not be called from atomic
    context.

    Remove support for this rarely-used format, as vsprintf() (and e.g.
    printk()) must be callable from any context.

    Any remaining out-of-tree users will start seeing the clock's name
    printed instead of its rate.

    Reported-by: Jia-Ju Bai
    Fixes: 900cca2944254edd ("lib/vsprintf: add %pC{,n,r} format specifiers for clocks")
    Link: http://lkml.kernel.org/r/1527845302-12159-5-git-send-email-geert+renesas@glider.be
    To: Jia-Ju Bai
    To: Jonathan Corbet
    To: Michael Turquette
    To: Stephen Boyd
    To: Zhang Rui
    To: Eduardo Valentin
    To: Eric Anholt
    To: Stefan Wahren
    To: Greg Kroah-Hartman
    Cc: Sergey Senozhatsky
    Cc: Petr Mladek
    Cc: Linus Torvalds
    Cc: Steven Rostedt
    Cc: linux-doc@vger.kernel.org
    Cc: linux-clk@vger.kernel.org
    Cc: linux-pm@vger.kernel.org
    Cc: linux-serial@vger.kernel.org
    Cc: linux-arm-kernel@lists.infradead.org
    Cc: linux-renesas-soc@vger.kernel.org
    Cc: linux-kernel@vger.kernel.org
    Cc: Geert Uytterhoeven
    Cc: stable@vger.kernel.org # 4.1+
    Signed-off-by: Geert Uytterhoeven
    Signed-off-by: Petr Mladek

    Geert Uytterhoeven
     
  • Pull locking updates from Ingo Molnar:

    - Lots of tidying up changes all across the map for Linux's formal
    memory/locking-model tooling, by Alan Stern, Akira Yokosawa, Andrea
    Parri, Paul E. McKenney and SeongJae Park.

    Notable changes beyond an overall update in the tooling itself is the
    tidying up of spin_is_locked() semantics, which spills over into the
    kernel proper as well.

    - qspinlock improvements: the locking algorithm now guarantees forward
    progress whereas the previous implementation in mainline could starve
    threads indefinitely in cmpxchg() loops. Also other related cleanups
    to the qspinlock code (Will Deacon)

    - misc smaller improvements, cleanups and fixes all across the locking
    subsystem

    * 'locking-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (51 commits)
    locking/rwsem: Simplify the is-owner-spinnable checks
    tools/memory-model: Add reference for 'Simplifying ARM concurrency'
    tools/memory-model: Update ASPLOS information
    MAINTAINERS, tools/memory-model: Update e-mail address for Andrea Parri
    tools/memory-model: Fix coding style in 'lock.cat'
    tools/memory-model: Remove out-of-date comments and code from lock.cat
    tools/memory-model: Improve mixed-access checking in lock.cat
    tools/memory-model: Improve comments in lock.cat
    tools/memory-model: Remove duplicated code from lock.cat
    tools/memory-model: Flag "cumulativity" and "propagation" tests
    tools/memory-model: Add model support for spin_is_locked()
    tools/memory-model: Add scripts to test memory model
    tools/memory-model: Fix coding style in 'linux-kernel.def'
    tools/memory-model: Model 'smp_store_mb()'
    tools/memory-order: Update the cheat-sheet to show that smp_mb__after_atomic() orders later RMW operations
    tools/memory-order: Improve key for SELF and SV
    tools/memory-model: Fix cheat sheet typo
    tools/memory-model: Update required version of herdtools7
    tools/memory-model: Redefine rb in terms of rcu-fence
    tools/memory-model: Rename link and rcu-path to rcu-link and rb
    ...

    Linus Torvalds
     

29 May, 2018

2 commits


15 May, 2018

2 commits

  • Use the proper RST directive, pointed out by a build warning.

    Signed-off-by: SeongJae Park
    Signed-off-by: Paul E. McKenney
    Cc: Andrew Morton
    Cc: Linus Torvalds
    Cc: Peter Zijlstra
    Cc: Thomas Gleixner
    Cc: Will Deacon
    Cc: akiyks@gmail.com
    Cc: boqun.feng@gmail.com
    Cc: dhowells@redhat.com
    Cc: j.alglave@ucl.ac.uk
    Cc: linux-arch@vger.kernel.org
    Cc: luc.maranget@inria.fr
    Cc: npiggin@gmail.com
    Cc: parri.andrea@gmail.com
    Cc: stern@rowland.harvard.edu
    Link: http://lkml.kernel.org/r/1526338533-6044-8-git-send-email-paulmck@linux.vnet.ibm.com
    Signed-off-by: Ingo Molnar

    SeongJae Park
     
  • - Remove a stale line of code
    - Fix the condition of the READ_ONCE() example

    Signed-off-by: SeongJae Park
    Signed-off-by: Paul E. McKenney
    Acked-by: Alan Stern
    Cc: Andrew Morton
    Cc: Linus Torvalds
    Cc: Peter Zijlstra
    Cc: Thomas Gleixner
    Cc: Will Deacon
    Cc: akiyks@gmail.com
    Cc: boqun.feng@gmail.com
    Cc: dhowells@redhat.com
    Cc: j.alglave@ucl.ac.uk
    Cc: linux-arch@vger.kernel.org
    Cc: luc.maranget@inria.fr
    Cc: npiggin@gmail.com
    Cc: parri.andrea@gmail.com
    Link: http://lkml.kernel.org/r/1526338533-6044-7-git-send-email-paulmck@linux.vnet.ibm.com
    Signed-off-by: Ingo Molnar

    SeongJae Park
     

09 May, 2018

3 commits


28 Apr, 2018

1 commit

  • Rearrange some kernel-api chapters and sections to group them
    together better.

    - move Bit Operations from Basic C Library Functions to Basic
    Kernel Library Functions (now adjacent to Bitmap Operations since
    they are not typical C library functions)

    - move Sorting from Math Functions to Basic Kernel Library Functions
    since sort functions are more Basic than Math Functions

    - move Text Searching from Math Functions to Basic Kernel Library
    Functions (keep Sorting and Searching close to each other)

    - combine CRC and Math functions together into the (newly named)
    CRC and Math Functions chapter

    Signed-off-by: Randy Dunlap
    Acked-by: Matthew Wilcox
    Signed-off-by: Jonathan Corbet

    Randy Dunlap
     

17 Apr, 2018

1 commit

  • Make lib/textsearch.c usable as kernel-doc.
    Add textsearch() function family to kernel-api documentation.
    Fix kernel-doc warnings in :
    ../include/linux/textsearch.h:65: warning: Incorrect use of kernel-doc format:
    * get_next_block - fetch next block of data
    ../include/linux/textsearch.h:82: warning: Incorrect use of kernel-doc format:
    * finish - finalize/clean a series of get_next_block() calls

    Signed-off-by: Randy Dunlap
    Signed-off-by: David S. Miller

    Randy Dunlap
     

24 Mar, 2018

1 commit


07 Feb, 2018

1 commit


02 Feb, 2018

1 commit

  • Pull printk updates from Petr Mladek:

    - Add a console_msg_format command line option:

    The value "default" keeps the old "[time stamp] text\n" format. The
    value "syslog" allows to see the syslog-like "[timestamp] text" format.

    This feature was requested by people doing regression tests, for
    example, 0day robot. They want to have both filtered and full logs
    at hands.

    - Reduce the risk of softlockup:

    Pass the console owner in a busy loop.

    This is a new approach to the old problem. It was first proposed by
    Steven Rostedt on Kernel Summit 2017. It marks a context in which
    the console_lock owner calls console drivers and could not sleep.
    On the other side, printk() callers could detect this state and use
    a busy wait instead of a simple console_trylock(). Finally, the
    console_lock owner checks if there is a busy waiter at the end of
    the special context and eventually passes the console_lock to the
    waiter.

    The hand-off works surprisingly well and helps in many situations.
    Well, there is still a possibility of the softlockup, for example,
    when the flood of messages stops and the last owner still has too
    much to flush.

    There is increasing number of people having problems with
    printk-related softlockups. We might eventually need to get better
    solution. Anyway, this looks like a good start and promising
    direction.

    - Do not allow to schedule in console_unlock() called from printk():

    This reverts an older controversial commit. The reschedule helped
    to avoid softlockups. But it also slowed down the console output.
    This patch is obsoleted by the new console waiter logic described
    above. In fact, the reschedule made the hand-off less effective.

    - Deprecate "%pf" and "%pF" format specifier:

    It was needed on ia64, ppc64 and parisc64 to dereference function
    descriptors and show the real function address. It is done
    transparently by "%ps" and "pS" format specifier now.

    Sergey Senozhatsky found that all the function descriptors were in
    a special elf section and could be easily detected.

    - Remove printk_symbol() API:

    It has been obsoleted by "%pS" format specifier, and this change
    helped to remove few continuous lines and a less intuitive old API.

    - Remove redundant memsets:

    Sergey removed unnecessary memset when processing printk.devkmsg
    command line option.

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/pmladek/printk: (27 commits)
    printk: drop redundant devkmsg_log_str memsets
    printk: Never set console_may_schedule in console_trylock()
    printk: Hide console waiter logic into helpers
    printk: Add console owner and waiter logic to load balance console writes
    kallsyms: remove print_symbol() function
    checkpatch: add pF/pf deprecation warning
    symbol lookup: introduce dereference_symbol_descriptor()
    parisc64: Add .opd based function descriptor dereference
    powerpc64: Add .opd based function descriptor dereference
    ia64: Add .opd based function descriptor dereference
    sections: split dereference_function_descriptor()
    openrisc: Fix conflicting types for _exext and _stext
    lib: do not use print_symbol()
    irq debug: do not use print_symbol()
    sysfs: do not use print_symbol()
    drivers: do not use print_symbol()
    x86: do not use print_symbol()
    unicore32: do not use print_symbol()
    sh: do not use print_symbol()
    mn10300: do not use print_symbol()
    ...

    Linus Torvalds
     

02 Jan, 2018

1 commit

  • - Move errseq.rst into core-api
    - Add errseq to the core-api index
    - Promote the header to a more prominent header type, otherwise we get three
    entries in the table of contents.
    - Reformat the table to look nicer and be a little more proportional in
    terms of horizontal width per bit (the SF bit is still disproportionately
    large, but there's no way to fix that).
    - Include errseq kernel-doc in the errseq.rst
    - Neaten some kernel-doc markup

    Signed-off-by: Matthew Wilcox
    Reviewed-by: Jeff Layton
    Reviewed-by: Randy Dunlap
    Signed-off-by: Jonathan Corbet

    Matthew Wilcox
     

22 Dec, 2017

1 commit

  • Documentation/printk-formats.txt is a candidate for conversion to
    ReStructuredText format. Some effort has already been made to do this
    conversion even thought the suffix is currently .txt

    Changes required to complete conversion

    - Move printk-formats.txt to core-api/printk-formats.rst
    - Add entry to Documentation/core-api/index.rst
    - Remove entry from Documentation/00-INDEX
    - Fix minor grammatical errors.
    - Order heading adornments as suggested by rst docs.
    - Use 'Passed by reference' uniformly.
    - Update pointer documentation around %px specifier.
    - Fix erroneous double backticks (to commas).
    - Remove extraneous double backticks (suggested by Jonathan Corbet).
    - Simplify documentation for kobject.

    Signed-off-by: Tobin C. Harding
    [jc: downcased "kernel"]
    Signed-off-by: Jonathan Corbet

    Tobin C. Harding
     

12 Dec, 2017

3 commits


02 Dec, 2017

1 commit

  • In code blocks, :c:func:`...` annotations don't result in
    cross-references. Instead, they are rendered verbatim. Remove these
    broken annotations, and mark function calls with parentheses() again.

    Fixes: 76d40fae1351 ("genericirq.rst: add cross-reference links and use monospaced fonts")
    Signed-off-by: Jonathan Neuschäfer
    Signed-off-by: Jonathan Corbet

    Jonathan Neuschäfer
     

22 Nov, 2017

1 commit


14 Nov, 2017

1 commit

  • Pull documentation updates from Jonathan Corbet:
    "A relatively calm cycle for the docs tree again.

    - The old driver statement has been added to the kernel docs.

    - We have a couple of new helper scripts. find-unused-docs.sh from
    Sayli Karnic will point out kerneldoc comments that are not actually
    used in the documentation. Jani Nikula's
    documentation-file-ref-check finds references to non-existing files.

    - A new ftrace document from Steve Rostedt.

    - Vinod Koul converted the dmaengine docs to RST

    Beyond that, it's mostly simple fixes.

    This set reaches outside of Documentation/ a bit more than most. In
    all cases, the changes are to comment docs, mostly from Randy, in
    places where there didn't seem to be anybody better to take them"

    * tag 'docs-4.15' of git://git.lwn.net/linux: (52 commits)
    documentation: fb: update list of available compiled-in fonts
    MAINTAINERS: update DMAengine documentation location
    dmaengine: doc: ReSTize pxa_dma doc
    dmaengine: doc: ReSTize dmatest doc
    dmaengine: doc: ReSTize client API doc
    dmaengine: doc: ReSTize provider doc
    dmaengine: doc: Add ReST style dmaengine document
    ftrace/docs: Add documentation on how to use ftrace from within the kernel
    bug-hunting.rst: Fix an example and a typo in a Sphinx tag
    scripts: Add a script to find unused documentation
    samples: Convert timers to use timer_setup()
    documentation: kernel-api: add more info on bitmap functions
    Documentation: fix selftests related file refs
    Documentation: fix ref to power basic-pm-debugging
    Documentation: fix ref to trace stm content
    Documentation: fix ref to coccinelle content
    Documentation: fix ref to workqueue content
    Documentation: fix ref to sphinx/kerneldoc.py
    Documentation: fix locking rt-mutex doc refs
    docs: dev-tools: correct Coccinelle version number
    ...

    Linus Torvalds
     

20 Oct, 2017

2 commits

  • Commit 764f80798b95 ("doc: Add RCU files to docbook-generation files")
    added :external: options for RCU source files in the file
    Documentation/core-api/kernel-api.rst. However, this now means nothing,
    so this commit removes them.

    Reported-by: Randy Dunlap
    Reported-by: Akira Yokosawa
    Signed-off-by: Paul E. McKenney
    Signed-off-by: Linus Torvalds

    Paul E. McKenney
     
  • There are some good comments about bitmap operations in lib/bitmap.c
    and include/linux/bitmap.h, so format them for document generation and
    pull them into core-api/kernel-api.rst.

    I converted the "tables" of functions from using tabs to using spaces
    so that they are more readable in the source file and in the generated
    output.

    Signed-off-by: Randy Dunlap
    Signed-off-by: Jonathan Corbet

    Randy Dunlap
     

08 Oct, 2017

1 commit


27 Sep, 2017

2 commits