Re: [PATCH v15 00/16] Add audio support in v4l2 framework

2024-05-03 Thread Mauro Carvalho Chehab
Em Fri, 3 May 2024 10:47:19 +0900
Mark Brown  escreveu:

> On Thu, May 02, 2024 at 10:26:43AM +0100, Mauro Carvalho Chehab wrote:
> > Mauro Carvalho Chehab  escreveu:  
> 
> > > There are still time control associated with it, as audio and video
> > > needs to be in sync. This is done by controlling the buffers size 
> > > and could be fine-tuned by checking when the buffer transfer is done.  
> 
> ...
> 
> > Just complementing: on media, we do this per video buffer (or
> > per half video buffer). A typical use case on cameras is to have
> > buffers transferred 30 times per second, if the video was streamed 
> > at 30 frames per second.   
> 
> IIRC some big use case for this hardware was transcoding so there was a
> desire to just go at whatever rate the hardware could support as there
> is no interactive user consuming the output as it is generated.

Indeed, codecs could be used to just do transcoding, but I would
expect it to be a border use case. See, as the chipsets implementing 
codecs are typically the ones used on mobiles, I would expect that
the major use cases to be to watch audio and video and to participate
on audio/video conferences.

Going further, the codec API may end supporting not only transcoding
(which is something that CPU can usually handle without too much
processing) but also audio processing that may require more 
complex algorithms - even deep learning ones - like background noise
removal, echo detection/removal, volume auto-gain, audio enhancement
and such.

On other words, the typical use cases will either have input
or output being a physical hardware (microphone or speaker).

> > I would assume that, on an audio/video stream, the audio data
> > transfer will be programmed to also happen on a regular interval.  
> 
> With audio the API is very much "wake userspace every Xms".


Re: [PATCH v15 00/16] Add audio support in v4l2 framework

2024-05-02 Thread Mauro Carvalho Chehab
Em Thu, 2 May 2024 09:59:56 +0100
Mauro Carvalho Chehab  escreveu:

> Em Thu, 02 May 2024 09:46:14 +0200
> Takashi Iwai  escreveu:
> 
> > On Wed, 01 May 2024 03:56:15 +0200,
> > Mark Brown wrote:
> > > 
> > > On Tue, Apr 30, 2024 at 05:27:52PM +0100, Mauro Carvalho Chehab wrote:  
> > > > Mark Brown  escreveu:  
> > > > > On Tue, Apr 30, 2024 at 10:21:12AM +0200, Sebastian Fricke wrote:  
> > >   
> > > > > The discussion around this originally was that all the audio APIs are
> > > > > very much centered around real time operations rather than completely 
> > > > >  
> > >   
> > > > The media subsystem is also centered around real time. Without real
> > > > time, you can't have a decent video conference system. Having
> > > > mem2mem transfers actually help reducing real time delays, as it 
> > > > avoids extra latency due to CPU congestion and/or data transfers
> > > > from/to userspace.  
> > > 
> > > Real time means strongly tied to wall clock times rather than fast - the
> > > issue was that all the ALSA APIs are based around pushing data through
> > > the system based on a clock.
> > >   
> > > > > That doesn't sound like an immediate solution to maintainer overload
> > > > > issues...  if something like this is going to happen the DRM solution
> > > > > does seem more general but I'm not sure the amount of stop energy is
> > > > > proportionate.  
> > >   
> > > > I don't think maintainer overload is the issue here. The main
> > > > point is to avoid a fork at the audio uAPI, plus the burden
> > > > of re-inventing the wheel with new codes for audio formats,
> > > > new documentation for them, etc.  
> > > 
> > > I thought that discussion had been had already at one of the earlier
> > > versions?  TBH I've not really been paying attention to this since the
> > > very early versions where I raised some similar "why is this in media"
> > > points and I thought everyone had decided that this did actually make
> > > sense.  
> > 
> > Yeah, it was discussed in v1 and v2 threads, e.g.
> >   
> > https://patchwork.kernel.org/project/linux-media/cover/1690265540-25999-1-git-send-email-shengjiu.w...@nxp.com/#25485573
> > 
> > My argument at that time was how the operation would be, and the point
> > was that it'd be a "batch-like" operation via M2M without any timing
> > control.  It'd be a very special usage for for ALSA, and if any, it'd
> > be hwdep -- that is a very hardware-specific API implementation -- or
> > try compress-offload API, which looks dubious.
> > 
> > OTOH, the argument was that there is already a framework for M2M in
> > media API and that also fits for the batch-like operation, too.  So
> > was the thread evolved until now.
> 
> M2M transfers are not a hardware-specific API, and such kind of
> transfers is not new either. Old media devices like bttv have
> internally a way to do PCI2PCI transfers, allowing media streams
> to be transferred directly without utilizing CPU. The media driver
> supports it for video, as this made a huge difference of performance
> back then.
> 
> On embedded world, this is a pretty common scenario: different media
> IP blocks can communicate with each other directly via memory. This
> can happen for video capture, video display and audio.
> 
> With M2M, most of the control is offloaded to the hardware.
> 
> There are still time control associated with it, as audio and video
> needs to be in sync. This is done by controlling the buffers size 
> and could be fine-tuned by checking when the buffer transfer is done.
> 
> On media, M2M buffer transfers are started via VIDIOC_QBUF,
> which is a request to do a frame transfer. A similar ioctl
> (VIDIOC_DQBUF) is used to monitor when the hardware finishes
> transfering the buffer. On other words, the CPU is responsible
> for time control.

Just complementing: on media, we do this per video buffer (or
per half video buffer). A typical use case on cameras is to have
buffers transferred 30 times per second, if the video was streamed 
at 30 frames per second. 

I would assume that, on an audio/video stream, the audio data
transfer will be programmed to also happen on a regular interval.

So, if the video stream is programmed to a 30 frames per second
rate, I would assume that the associated audio stream will also be
programmed to be grouped into 30 data transfers per second. On such
scenario, if the audio is sampled at 48 kHZ, it means that:

1) each M2M transfer commanded by CPU will copy 1600 samples;
2) the time between each sample will remain 1/48000;
3) a notification event telling that 1600 samples were transferred
   will be generated when the last sample happens;
4) CPU will do time control by looking at the notification events.

> On other words, this is still real time. The main difference
> from a "sync" transfer is that the CPU doesn't need to copy data
> from/to different devices, as such operation is offloaded to the
> hardware.
> 
> Regards,
> Mauro


Re: [PATCH v15 00/16] Add audio support in v4l2 framework

2024-05-02 Thread Mauro Carvalho Chehab
Em Thu, 02 May 2024 09:46:14 +0200
Takashi Iwai  escreveu:

> On Wed, 01 May 2024 03:56:15 +0200,
> Mark Brown wrote:
> > 
> > On Tue, Apr 30, 2024 at 05:27:52PM +0100, Mauro Carvalho Chehab wrote:  
> > > Mark Brown  escreveu:  
> > > > On Tue, Apr 30, 2024 at 10:21:12AM +0200, Sebastian Fricke wrote:  
> >   
> > > > The discussion around this originally was that all the audio APIs are
> > > > very much centered around real time operations rather than completely  
> >   
> > > The media subsystem is also centered around real time. Without real
> > > time, you can't have a decent video conference system. Having
> > > mem2mem transfers actually help reducing real time delays, as it 
> > > avoids extra latency due to CPU congestion and/or data transfers
> > > from/to userspace.  
> > 
> > Real time means strongly tied to wall clock times rather than fast - the
> > issue was that all the ALSA APIs are based around pushing data through
> > the system based on a clock.
> >   
> > > > That doesn't sound like an immediate solution to maintainer overload
> > > > issues...  if something like this is going to happen the DRM solution
> > > > does seem more general but I'm not sure the amount of stop energy is
> > > > proportionate.  
> >   
> > > I don't think maintainer overload is the issue here. The main
> > > point is to avoid a fork at the audio uAPI, plus the burden
> > > of re-inventing the wheel with new codes for audio formats,
> > > new documentation for them, etc.  
> > 
> > I thought that discussion had been had already at one of the earlier
> > versions?  TBH I've not really been paying attention to this since the
> > very early versions where I raised some similar "why is this in media"
> > points and I thought everyone had decided that this did actually make
> > sense.  
> 
> Yeah, it was discussed in v1 and v2 threads, e.g.
>   
> https://patchwork.kernel.org/project/linux-media/cover/1690265540-25999-1-git-send-email-shengjiu.w...@nxp.com/#25485573
> 
> My argument at that time was how the operation would be, and the point
> was that it'd be a "batch-like" operation via M2M without any timing
> control.  It'd be a very special usage for for ALSA, and if any, it'd
> be hwdep -- that is a very hardware-specific API implementation -- or
> try compress-offload API, which looks dubious.
> 
> OTOH, the argument was that there is already a framework for M2M in
> media API and that also fits for the batch-like operation, too.  So
> was the thread evolved until now.

M2M transfers are not a hardware-specific API, and such kind of
transfers is not new either. Old media devices like bttv have
internally a way to do PCI2PCI transfers, allowing media streams
to be transferred directly without utilizing CPU. The media driver
supports it for video, as this made a huge difference of performance
back then.

On embedded world, this is a pretty common scenario: different media
IP blocks can communicate with each other directly via memory. This
can happen for video capture, video display and audio.

With M2M, most of the control is offloaded to the hardware.

There are still time control associated with it, as audio and video
needs to be in sync. This is done by controlling the buffers size 
and could be fine-tuned by checking when the buffer transfer is done.

On media, M2M buffer transfers are started via VIDIOC_QBUF,
which is a request to do a frame transfer. A similar ioctl
(VIDIOC_DQBUF) is used to monitor when the hardware finishes
transfering the buffer. On other words, the CPU is responsible
for time control.

On other words, this is still real time. The main difference
from a "sync" transfer is that the CPU doesn't need to copy data
from/to different devices, as such operation is offloaded to the
hardware.

Regards,
Mauro


Re: [PATCH v15 00/16] Add audio support in v4l2 framework

2024-04-30 Thread Mauro Carvalho Chehab
Em Tue, 30 Apr 2024 23:46:03 +0900
Mark Brown  escreveu:

> On Tue, Apr 30, 2024 at 10:21:12AM +0200, Sebastian Fricke wrote:
> 
> > first of all thanks for all of this work and I am very sorry for only
> > emerging this late into the series, I sadly didn't notice it earlier.  
> 
> It might be worth checking out the discussion on earlier versions...
> 
> > 1. The biggest objection is, that the Linux Kernel has a subsystem
> > specifically targeted for audio devices, adding support for these
> > devices in another subsystem are counterproductive as they work around
> > the shortcomings of the audio subsystem while forcing support for a
> > device into a subsystem that was never designed for such devices.
> > Instead, the audio subsystem has to be adjusted to be able to support
> > all of the required workflows, otherwise, the next audio driver with
> > similar requirements will have to move to the media subsystem as well,
> > the audio subsystem would then never experience the required change and
> > soon we would have two audio subsystems.  
> 
> The discussion around this originally was that all the audio APIs are
> very much centered around real time operations rather than completely
> async memory to memory operations and that it's not clear that it's
> worth reinventing the wheel simply for the sake of having things in
> ALSA when that's already pretty idiomatic for the media subsystem.  It
> wasn't the memory to memory bit per se, it was the disconnection from
> any timing.

The media subsystem is also centered around real time. Without real
time, you can't have a decent video conference system. Having
mem2mem transfers actually help reducing real time delays, as it 
avoids extra latency due to CPU congestion and/or data transfers
from/to userspace.

> 
> > So instead of hammering a driver into the wrong destination, I would
> > suggest bundling our forces and implementing a general memory-to-memory
> > framework that both the media and the audio subsystem can use, that
> > addresses the current shortcomings of the implementation and allows you
> > to upload the driver where it is supposed to be.  
> 
> That doesn't sound like an immediate solution to maintainer overload
> issues...  if something like this is going to happen the DRM solution
> does seem more general but I'm not sure the amount of stop energy is
> proportionate.

I don't think maintainer overload is the issue here. The main
point is to avoid a fork at the audio uAPI, plus the burden
of re-inventing the wheel with new codes for audio formats,
new documentation for them, etc.

Regards,
Mauro


Re: [PATCH v15 00/16] Add audio support in v4l2 framework

2024-04-30 Thread Mauro Carvalho Chehab
Em Tue, 30 Apr 2024 10:47:13 +0200
Hans Verkuil  escreveu:

> On 30/04/2024 10:21, Sebastian Fricke wrote:
> > Hey Shengjiu,
> > 
> > first of all thanks for all of this work and I am very sorry for only
> > emerging this late into the series, I sadly didn't notice it earlier.
> > 
> > I would like to voice a few concerns about the general idea of adding
> > Audio support to the Media subsystem.
> > 
> > 1. The biggest objection is, that the Linux Kernel has a subsystem
> > specifically targeted for audio devices, adding support for these
> > devices in another subsystem are counterproductive as they work around
> > the shortcomings of the audio subsystem while forcing support for a
> > device into a subsystem that was never designed for such devices.
> > Instead, the audio subsystem has to be adjusted to be able to support
> > all of the required workflows, otherwise, the next audio driver with
> > similar requirements will have to move to the media subsystem as well,
> > the audio subsystem would then never experience the required change and
> > soon we would have two audio subsystems.
> > 
> > 2. Closely connected to the previous objection, the media subsystem with
> > its current staff of maintainers is overworked and barely capable of
> > handling the workload, which includes an abundance of different devices
> > from DVB, codecs, cameras, PCI devices, radio tuners, HDMI CEC, IR
> > receivers, etc. Adding more device types to this matrix will make the
> > situation worse and should only be done with a plan for how first to
> > improve the current maintainer situation.
> > 
> > 3. By using the same framework and APIs as the video codecs, the audio
> > codecs are going to cause extra work for the video codec developers and
> > maintainers simply by occupying the same space that was orginally
> > designed for the purpose of video only. Even if you try to not cause any
> > extra stress the simple presence of the audio code in the codebase is
> > going to cause restrictions.
> > 
> > The main issue here is that the audio subsystem doesn't provide a
> > mem2mem framework and I would say you are in luck because the media
> > subsystem has gathered a lot of shortcomings with its current
> > implementation of the mem2mem framework over time, which is why a new
> > implementation will be necessary anyway.
> > 
> > So instead of hammering a driver into the wrong destination, I would
> > suggest bundling our forces and implementing a general memory-to-memory
> > framework that both the media and the audio subsystem can use, that
> > addresses the current shortcomings of the implementation and allows you
> > to upload the driver where it is supposed to be.
> > This is going to cause restrictions as well, like mentioned in the
> > concern number 3, but with the difference that we can make a general
> > plan for such a framework that accomodates lots of use cases and each
> > subsystem can add their routines on top of the general framework.
> > 
> > Another possible alternative is to try and make the DRM scheduler more
> > generally available, this scheduler is the most mature and in fact is
> > very similar to what you and what the media devices need.
> > Which again just shows how common your usecase actually is and how a
> > general solution is the best long term solution.
> > 
> > Please notice that Daniel Almeida is currently working on something
> > related to this:
> > https://lore.kernel.org/linux-media/3f80ac0d-dcaa-4ede-bf58-bb1369c7e...@collabora.com/T/#u
> > 
> > If the toplevel maintainers decide to add the patchset so be it, but I
> > wanted to voice my concerns and also highlight that this is likely going
> > to cause extra stress for the video codecs maintainers and the
> > maintainers in general. We cannot spend a lot of time on audio codecs,
> > as video codecs already fill up our available time sufficiently,
> > so the use of the framework needs to be conservative and cause as little
> > extra work as possible for the original use case of the framework.  
> 
> I would really like to get the input of the audio maintainers on this.
> Sebastian has a good point, especially with us being overworked :-)
> 
> Having a shared mem2mem framework would certainly be nice, on the other
> hand, developing that will most likely take a substantial amount of time.
> 
> Perhaps it is possible to copy the current media v4l2-mem2mem.c and turn
> it into an alsa-mem2mem.c? I really do not know enough about the alsa
> subsystem to tell if that is possible.
> 
> While this driver is a rate converter, not an audio codec, the same
> principles would apply to off-line audio codecs as well. And it is true
> that we definitely do not want to support audio codecs in the media
> subsystem.
> 
> Accepting this driver creates a precedent and would open the door for
> audio codecs.
> 
> I may have been too hasty in saying yes to this, I did not consider
> the wider implications for our workload and what it can lead to. I
> 

Re: [PATCH v12 08/15] media: uapi: Define audio sample format fourcc type

2024-02-19 Thread Mauro Carvalho Chehab
Em Mon, 19 Feb 2024 12:05:02 +0800
Shengjiu Wang  escreveu:

> Hi Mauro
> 
> On Sat, Feb 17, 2024 at 5:19 PM Mauro Carvalho Chehab
>  wrote:
> >
> > Em Thu, 18 Jan 2024 20:32:01 +0800
> > Shengjiu Wang  escreveu:
> >  
> > > The audio sample format definition is from alsa,
> > > the header file is include/uapi/sound/asound.h, but
> > > don't include this header file directly, because in
> > > user space, there is another copy in alsa-lib.
> > > There will be conflict in userspace for include
> > > videodev2.h & asound.h and asoundlib.h
> > >
> > > Here still use the fourcc format.
> > >
> > > Signed-off-by: Shengjiu Wang 
> > > ---
> > >  .../userspace-api/media/v4l/pixfmt-audio.rst  | 87 +++
> > >  .../userspace-api/media/v4l/pixfmt.rst|  1 +
> > >  drivers/media/v4l2-core/v4l2-ioctl.c  | 13 +++
> > >  include/uapi/linux/videodev2.h| 23 +
> > >  4 files changed, 124 insertions(+)
> > >  create mode 100644 Documentation/userspace-api/media/v4l/pixfmt-audio.rst
> > >
> > > diff --git a/Documentation/userspace-api/media/v4l/pixfmt-audio.rst 
> > > b/Documentation/userspace-api/media/v4l/pixfmt-audio.rst
> > > new file mode 100644
> > > index ..04b4a7fbd8f4
> > > --- /dev/null
> > > +++ b/Documentation/userspace-api/media/v4l/pixfmt-audio.rst
> > > @@ -0,0 +1,87 @@
> > > +.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
> > > +
> > > +.. _pixfmt-audio:
> > > +
> > > +*
> > > +Audio Formats
> > > +*
> > > +
> > > +These formats are used for :ref:`audiomem2mem` interface only.
> > > +
> > > +.. tabularcolumns:: |p{5.8cm}|p{1.2cm}|p{10.3cm}|
> > > +
> > > +.. cssclass:: longtable
> > > +
> > > +.. flat-table:: Audio Format
> > > +:header-rows:  1
> > > +:stub-columns: 0
> > > +:widths:   3 1 4
> > > +
> > > +* - Identifier
> > > +  - Code
> > > +  - Details
> > > +* .. _V4L2-AUDIO-FMT-S8:
> > > +
> > > +  - ``V4L2_AUDIO_FMT_S8``
> > > +  - 'S8'
> > > +  - Corresponds to SNDRV_PCM_FORMAT_S8 in ALSA
> > > +* .. _V4L2-AUDIO-FMT-S16-LE:  
> >
> > Hmm... why can't we just use SNDRV_*_FORMAT_*? Those are already part of
> > an uAPI header. No need to add any abstraction here and/or redefine
> > what is there already at include/uapi/sound/asound.h.
> >  
> Actually I try to avoid including the include/uapi/sound/asound.h.
> Because in user space, there is another copy in alsa-lib (asoundlib.h).
> There will be conflict in userspace when including videodev2.h and
> asoundlib.h.

Well, alsasoundlib.h seems to be using the same definitions:
https://github.com/michaelwu/alsa-lib/blob/master/include/pcm.h

So, I can't see what would be the actual issue, as both userspace library
and ALSA internal headers use the same magic numbers.

You can still do things like:

#ifdef __KERNEL__
#  include 
#else
#  include 
#endif

To avoid such kind of conflicts, if you need to have it included on
some header file. Yet, I can't see why you would need that.

IMO, at uAPI headers, you just need to declare the uAPI audiofmt field
to be either __u32 or __u64, pointing it to where this value comes from
(on both userspace and Kernelspace. E. g.:

/**
 * struct v4l2_audio_format - audio data format definition
 * @audioformat:
 *  an integer number matching the fields inside
 *  enum snd_pcm_format_t (e. g. `SNDRV_PCM_FORMAT_*`), as defined
 *  in include/uapi/sound/asound.h and
 *  
https://www.alsa-project.org/alsa-doc/alsa-lib/group___p_c_m.html#gaa14b7f26877a812acbb39811364177f8.
 * @channels:   channel numbers
 * @buffersize: maximum size in bytes required for data
 */
struct v4l2_audio_format {
__u32   audioformat;
__u32   channels;
__u32   buffersize;
} __attribute__ ((packed));

Then, at documentation you just need to point to where the
possible values for SNDRV_PCM_FORMAT_ are defined. No need to
document them one by one.

With such definition, you'll only need to include sound/asound.h
within the kAPI scope.

> 
> And in the V4l framework, the fourcc type is commonly used in other
> cases (video, radio, touch, meta), to avoid changing common code
> a lot, so I think using fourcc definition for audio may be simpler.

Those are real video streams (or a video-related streams, in the case
of metadata) where fourcc is widely used. There, it makes sense.
However, ALSA format definitions are already being used for a long time.
There's no sense on trying to reinvent it - or having an abstract layer
to convert from/to fourcc <==> enum snd_pcm_format_t. Just use what is
there already.

Thanks,
Mauro


Re: [PATCH v12 10/15] media: uapi: Add audio rate controls support

2024-02-19 Thread Mauro Carvalho Chehab
Em Mon, 19 Feb 2024 14:03:37 +0800
Shengjiu Wang  escreveu:

> On Sat, Feb 17, 2024 at 5:57 PM Mauro Carvalho Chehab
>  wrote:
> >
> > Em Thu, 18 Jan 2024 20:32:03 +0800
> > Shengjiu Wang  escreveu:
> >  
> > > Add V4L2_CID_M2M_AUDIO_SOURCE_RATE and V4L2_CID_M2M_AUDIO_DEST_RATE
> > > new IDs for rate control.
> > >
> > > Add V4L2_CID_M2M_AUDIO_SOURCE_RATE_OFFSET and
> > > V4L2_CID_M2M_AUDIO_DEST_RATE_OFFSET for clock drift.
> > >
> > > Signed-off-by: Shengjiu Wang 
> > > ---
> > >  .../media/v4l/ext-ctrls-audio-m2m.rst | 20 +++
> > >  drivers/media/v4l2-core/v4l2-ctrls-defs.c |  6 ++
> > >  include/uapi/linux/v4l2-controls.h|  5 +
> > >  3 files changed, 31 insertions(+)
> > >
> > > diff --git 
> > > a/Documentation/userspace-api/media/v4l/ext-ctrls-audio-m2m.rst 
> > > b/Documentation/userspace-api/media/v4l/ext-ctrls-audio-m2m.rst
> > > index 82d2ecedbfee..de579ab8fb94 100644
> > > --- a/Documentation/userspace-api/media/v4l/ext-ctrls-audio-m2m.rst
> > > +++ b/Documentation/userspace-api/media/v4l/ext-ctrls-audio-m2m.rst
> > > @@ -19,3 +19,23 @@ Audio M2M Control IDs
> > >  The Audio M2M class descriptor. Calling
> > >  :ref:`VIDIOC_QUERYCTRL` for this control will
> > >  return a description of this control class.
> > > +
> > > +.. _v4l2-audio-asrc:
> > > +
> > > +``V4L2_CID_M2M_AUDIO_SOURCE_RATE (integer menu)``
> > > +Sets the audio source sample rate, unit is Hz
> > > +
> > > +``V4L2_CID_M2M_AUDIO_DEST_RATE (integer menu)``
> > > +Sets the audio destination sample rate, unit is Hz
> > > +
> > > +``V4L2_CID_M2M_AUDIO_SOURCE_RATE_OFFSET (fixed point)``
> > > +Sets the offset from the audio source sample rate, unit is Hz.
> > > +The offset compensates for any clock drift. The actual source audio
> > > +sample rate is the ideal source audio sample rate from
> > > +``V4L2_CID_M2M_AUDIO_SOURCE_RATE`` plus this fixed point offset.
> > > +
> > > +``V4L2_CID_M2M_AUDIO_DEST_RATE_OFFSET (fixed point)``
> > > +Sets the offset from the audio destination sample rate, unit is Hz.
> > > +The offset compensates for any clock drift. The actual destination 
> > > audio
> > > +sample rate is the ideal source audio sample rate from
> > > +``V4L2_CID_M2M_AUDIO_DEST_RATE`` plus this fixed point offset.  
> >
> > Hmm... first of all, controls on V4L2 API can either be get or set.
> > So, starting the sentence with "Set" sounds an assumption that may
> > be wrong.  
> 
> Ok, will update the description.
> >
> > Also, I would explain a little bit more about the frequency offset values,
> > as clock drift adjustment on PCM streams is something that can be done
> > using different approaches.
> >
> > I'm assuming that what you wanted here is to use it to check if the
> > video and audio clocks have some drift, and reducing or increasing
> > the audio sample rate dynamically to ensure that such drift will
> > stay constraint to a maximum allowed drift measured in mili or nano
> > seconds. So, userspace would be expected to be monitoring such drift
> > and increasing/decreasing the sample frequency as needed to maintain
> > such constraint.
> >
> > Is that the way such uAPI is expected to work?  
> 
> Yes. Userspace should monitor the drift, get the offset based on the
> common sample rate (8k, 44.1k, 48k...) then send it to the driver.
> The offset is a fixed point. it is base on the patch:
> https://patchwork.kernel.org/project/linux-media/patch/cec82507-ced9-4e7d-802c-04a40f84a...@xs4all.nl/

Ok, so write a description about how this should be used (like the
test I written),to help userspace developers to better understand
how this uAPI should be used.

See, one of the main goals of the uAPI documentation is to ensure that
userspace programs will implement the uAPI bits the right way, behaving
the right way when using it. That's why we even have some userspace code 
examples for some ioctls. IMO frequence drift is one of such cases
where more explanation is needed.


> 
> Best regards
> Shengjiu Wang
> >  
> > > diff --git a/drivers/media/v4l2-core/v4l2-ctrls-defs.c 
> > > b/drivers/media/v4l2-core/v4l2-ctrls-defs.c
> > > index 2a85ea3dc92f..91e1f5348c23 100644
> > > --- a/drivers/media/v4l2-core/v4l2-ctrls-defs.c
> > > +++ b/drivers/media/v4l2-core/v4l2-ctrls-defs.c
> > > @@

Re: [PATCH v12 10/15] media: uapi: Add audio rate controls support

2024-02-17 Thread Mauro Carvalho Chehab
Em Thu, 18 Jan 2024 20:32:03 +0800
Shengjiu Wang  escreveu:

> Add V4L2_CID_M2M_AUDIO_SOURCE_RATE and V4L2_CID_M2M_AUDIO_DEST_RATE
> new IDs for rate control.
> 
> Add V4L2_CID_M2M_AUDIO_SOURCE_RATE_OFFSET and
> V4L2_CID_M2M_AUDIO_DEST_RATE_OFFSET for clock drift.
> 
> Signed-off-by: Shengjiu Wang 
> ---
>  .../media/v4l/ext-ctrls-audio-m2m.rst | 20 +++
>  drivers/media/v4l2-core/v4l2-ctrls-defs.c |  6 ++
>  include/uapi/linux/v4l2-controls.h|  5 +
>  3 files changed, 31 insertions(+)
> 
> diff --git a/Documentation/userspace-api/media/v4l/ext-ctrls-audio-m2m.rst 
> b/Documentation/userspace-api/media/v4l/ext-ctrls-audio-m2m.rst
> index 82d2ecedbfee..de579ab8fb94 100644
> --- a/Documentation/userspace-api/media/v4l/ext-ctrls-audio-m2m.rst
> +++ b/Documentation/userspace-api/media/v4l/ext-ctrls-audio-m2m.rst
> @@ -19,3 +19,23 @@ Audio M2M Control IDs
>  The Audio M2M class descriptor. Calling
>  :ref:`VIDIOC_QUERYCTRL` for this control will
>  return a description of this control class.
> +
> +.. _v4l2-audio-asrc:
> +
> +``V4L2_CID_M2M_AUDIO_SOURCE_RATE (integer menu)``
> +Sets the audio source sample rate, unit is Hz
> +
> +``V4L2_CID_M2M_AUDIO_DEST_RATE (integer menu)``
> +Sets the audio destination sample rate, unit is Hz
> +
> +``V4L2_CID_M2M_AUDIO_SOURCE_RATE_OFFSET (fixed point)``
> +Sets the offset from the audio source sample rate, unit is Hz.
> +The offset compensates for any clock drift. The actual source audio
> +sample rate is the ideal source audio sample rate from
> +``V4L2_CID_M2M_AUDIO_SOURCE_RATE`` plus this fixed point offset.
> +
> +``V4L2_CID_M2M_AUDIO_DEST_RATE_OFFSET (fixed point)``
> +Sets the offset from the audio destination sample rate, unit is Hz.
> +The offset compensates for any clock drift. The actual destination audio
> +sample rate is the ideal source audio sample rate from
> +``V4L2_CID_M2M_AUDIO_DEST_RATE`` plus this fixed point offset.

Hmm... first of all, controls on V4L2 API can either be get or set.
So, starting the sentence with "Set" sounds an assumption that may
be wrong.

Also, I would explain a little bit more about the frequency offset values,
as clock drift adjustment on PCM streams is something that can be done
using different approaches.

I'm assuming that what you wanted here is to use it to check if the
video and audio clocks have some drift, and reducing or increasing
the audio sample rate dynamically to ensure that such drift will
stay constraint to a maximum allowed drift measured in mili or nano
seconds. So, userspace would be expected to be monitoring such drift
and increasing/decreasing the sample frequency as needed to maintain
such constraint.

Is that the way such uAPI is expected to work?

> diff --git a/drivers/media/v4l2-core/v4l2-ctrls-defs.c 
> b/drivers/media/v4l2-core/v4l2-ctrls-defs.c
> index 2a85ea3dc92f..91e1f5348c23 100644
> --- a/drivers/media/v4l2-core/v4l2-ctrls-defs.c
> +++ b/drivers/media/v4l2-core/v4l2-ctrls-defs.c
> @@ -1245,6 +1245,8 @@ const char *v4l2_ctrl_get_name(u32 id)
>  
>   /* Audio M2M controls */
>   case V4L2_CID_M2M_AUDIO_CLASS:  return "Audio M2M Controls";
> + case V4L2_CID_M2M_AUDIO_SOURCE_RATE:return "Audio Source Sample 
> Rate";
> + case V4L2_CID_M2M_AUDIO_DEST_RATE:  return "Audio Destination 
> Sample Rate";
>   default:
>   return NULL;
>   }
> @@ -1606,6 +1608,10 @@ void v4l2_ctrl_fill(u32 id, const char **name, enum 
> v4l2_ctrl_type *type,
>   case V4L2_CID_COLORIMETRY_HDR10_MASTERING_DISPLAY:
>   *type = V4L2_CTRL_TYPE_HDR10_MASTERING_DISPLAY;
>   break;
> + case V4L2_CID_M2M_AUDIO_SOURCE_RATE:
> + case V4L2_CID_M2M_AUDIO_DEST_RATE:
> + *type = V4L2_CTRL_TYPE_INTEGER_MENU;
> + break;
>   default:
>   *type = V4L2_CTRL_TYPE_INTEGER;
>   break;
> diff --git a/include/uapi/linux/v4l2-controls.h 
> b/include/uapi/linux/v4l2-controls.h
> index a8b4b830c757..30129ccdc282 100644
> --- a/include/uapi/linux/v4l2-controls.h
> +++ b/include/uapi/linux/v4l2-controls.h
> @@ -3495,6 +3495,11 @@ struct v4l2_ctrl_av1_film_grain {
>  #define V4L2_CID_M2M_AUDIO_CLASS_BASE  (V4L2_CTRL_CLASS_M2M_AUDIO | 0x900)
>  #define V4L2_CID_M2M_AUDIO_CLASS   (V4L2_CTRL_CLASS_M2M_AUDIO | 1)
>  
> +#define V4L2_CID_M2M_AUDIO_SOURCE_RATE   (V4L2_CID_M2M_AUDIO_CLASS_BASE 
> + 0)
> +#define V4L2_CID_M2M_AUDIO_DEST_RATE (V4L2_CID_M2M_AUDIO_CLASS_BASE + 1)
> +#define V4L2_CID_M2M_AUDIO_SOURCE_RATE_OFFSET
> (V4L2_CID_M2M_AUDIO_CLASS_BASE + 2)
> +#define V4L2_CID_M2M_AUDIO_DEST_RATE_OFFSET  (V4L2_CID_M2M_AUDIO_CLASS_BASE 
> + 3)
> +
>  /* MPEG-compression definitions kept for backwards compatibility */
>  #ifndef __KERNEL__
>  #define V4L2_CTRL_CLASS_MPEGV4L2_CTRL_CLASS_CODEC



Thanks,
Mauro


Re: [PATCH v12 07/15] media: v4l2: Add audio capture and output support

2024-02-17 Thread Mauro Carvalho Chehab
Em Thu, 18 Jan 2024 20:32:00 +0800
Shengjiu Wang  escreveu:

> Audio signal processing has the requirement for memory to
> memory similar as Video.
> 
> This patch is to add this support in v4l2 framework, defined
> new buffer type V4L2_BUF_TYPE_AUDIO_CAPTURE and
> V4L2_BUF_TYPE_AUDIO_OUTPUT, defined new format v4l2_audio_format
> for audio case usage.
> 
> The created audio device is named "/dev/v4l-audioX".
> 
> Signed-off-by: Shengjiu Wang 
> ---
>  .../userspace-api/media/v4l/buffer.rst|  6 ++
>  .../media/v4l/dev-audio-mem2mem.rst   | 71 +++
>  .../userspace-api/media/v4l/devices.rst   |  1 +
>  .../media/v4l/vidioc-enum-fmt.rst |  2 +
>  .../userspace-api/media/v4l/vidioc-g-fmt.rst  |  4 ++
>  .../media/videodev2.h.rst.exceptions  |  2 +
>  .../media/common/videobuf2/videobuf2-v4l2.c   |  4 ++
>  drivers/media/v4l2-core/v4l2-compat-ioctl32.c |  9 +++
>  drivers/media/v4l2-core/v4l2-dev.c| 17 +
>  drivers/media/v4l2-core/v4l2-ioctl.c  | 53 ++
>  include/media/v4l2-dev.h  |  2 +
>  include/media/v4l2-ioctl.h| 34 +
>  include/uapi/linux/videodev2.h| 17 +
>  13 files changed, 222 insertions(+)
>  create mode 100644 
> Documentation/userspace-api/media/v4l/dev-audio-mem2mem.rst
> 
> diff --git a/Documentation/userspace-api/media/v4l/buffer.rst 
> b/Documentation/userspace-api/media/v4l/buffer.rst
> index 52bbee81c080..a3754ca6f0d6 100644
> --- a/Documentation/userspace-api/media/v4l/buffer.rst
> +++ b/Documentation/userspace-api/media/v4l/buffer.rst
> @@ -438,6 +438,12 @@ enum v4l2_buf_type
>  * - ``V4L2_BUF_TYPE_META_OUTPUT``
>- 14

>- Buffer for metadata output, see :ref:`metadata`.
> +* - ``V4L2_BUF_TYPE_AUDIO_CAPTURE``
> +  - 15
> +  - Buffer for audio capture, see :ref:`audio`.
> +* - ``V4L2_BUF_TYPE_AUDIO_OUTPUT``
> +  - 16

Hmm... alsa APi define input/output as:
enum {
SNDRV_PCM_STREAM_PLAYBACK = 0,
SNDRV_PCM_STREAM_CAPTURE,
SNDRV_PCM_STREAM_LAST = SNDRV_PCM_STREAM_CAPTURE,
};


I would use a namespace as close as possible to the
ALSA API. Also, we're not talking about V4L2, but, instead
audio. so, not sure if I like the prefix to start with
V4L2_. Maybe ALSA_?

So, a better namespace would be:

${prefix}_BUF_TYPE_PCM_STREAM_PLAYBACK
and
${prefix}_BUF_TYPE_PCM_STREAM_CAPTURE

> +  - Buffer for audio output, see :ref:`audio`.
>  
>  
>  .. _buffer-flags:
> diff --git a/Documentation/userspace-api/media/v4l/dev-audio-mem2mem.rst 
> b/Documentation/userspace-api/media/v4l/dev-audio-mem2mem.rst
> new file mode 100644
> index ..68faecfe3a02
> --- /dev/null
> +++ b/Documentation/userspace-api/media/v4l/dev-audio-mem2mem.rst
> @@ -0,0 +1,71 @@
> +.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
> +
> +.. _audiomem2mem:
> +
> +
> +Audio Memory-To-Memory Interface
> +
> +
> +An audio memory-to-memory device can compress, decompress, transform, or
> +otherwise convert audio data from one format into another format, in memory.
> +Such memory-to-memory devices set the ``V4L2_CAP_AUDIO_M2M`` capability.
> +Examples of memory-to-memory devices are audio codecs, audio preprocessing,
> +audio postprocessing.
> +
> +A memory-to-memory audio node supports both output (sending audio frames from
> +memory to the hardware) and capture (receiving the processed audio frames
> +from the hardware into memory) stream I/O. An application will have to
> +setup the stream I/O for both sides and finally call
> +:ref:`VIDIOC_STREAMON ` for both capture and output to
> +start the hardware.
> +
> +Memory-to-memory devices function as a shared resource: you can
> +open the audio node multiple times, each application setting up their
> +own properties that are local to the file handle, and each can use
> +it independently from the others. The driver will arbitrate access to
> +the hardware and reprogram it whenever another file handler gets access.
> +
> +Audio memory-to-memory devices are accessed through character device
> +special files named ``/dev/v4l-audio``
> +
> +Querying Capabilities
> +=
> +
> +Device nodes supporting the audio memory-to-memory interface set the
> +``V4L2_CAP_AUDIO_M2M`` flag in the ``device_caps`` field of the
> +:c:type:`v4l2_capability` structure returned by the :c:func:`VIDIOC_QUERYCAP`
> +ioctl.
> +
> +Data Format Negotiation
> +===
> +
> +The audio device uses the :ref:`format` ioctls to select the capture format.
> +The audio buffer content format is bound to that selected format. In addition
> +to the basic :ref:`format` ioctls, the :c:func:`VIDIOC_ENUM_FMT` ioctl must 
> be
> +supported as well.
> +
> +To use the :ref:`format` ioctls applications set the ``type`` field of the
> 

Re: [PATCH v12 08/15] media: uapi: Define audio sample format fourcc type

2024-02-17 Thread Mauro Carvalho Chehab
Em Thu, 18 Jan 2024 20:32:01 +0800
Shengjiu Wang  escreveu:

> The audio sample format definition is from alsa,
> the header file is include/uapi/sound/asound.h, but
> don't include this header file directly, because in
> user space, there is another copy in alsa-lib.
> There will be conflict in userspace for include
> videodev2.h & asound.h and asoundlib.h
> 
> Here still use the fourcc format.
> 
> Signed-off-by: Shengjiu Wang 
> ---
>  .../userspace-api/media/v4l/pixfmt-audio.rst  | 87 +++
>  .../userspace-api/media/v4l/pixfmt.rst|  1 +
>  drivers/media/v4l2-core/v4l2-ioctl.c  | 13 +++
>  include/uapi/linux/videodev2.h| 23 +
>  4 files changed, 124 insertions(+)
>  create mode 100644 Documentation/userspace-api/media/v4l/pixfmt-audio.rst
> 
> diff --git a/Documentation/userspace-api/media/v4l/pixfmt-audio.rst 
> b/Documentation/userspace-api/media/v4l/pixfmt-audio.rst
> new file mode 100644
> index ..04b4a7fbd8f4
> --- /dev/null
> +++ b/Documentation/userspace-api/media/v4l/pixfmt-audio.rst
> @@ -0,0 +1,87 @@
> +.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
> +
> +.. _pixfmt-audio:
> +
> +*
> +Audio Formats
> +*
> +
> +These formats are used for :ref:`audiomem2mem` interface only.
> +
> +.. tabularcolumns:: |p{5.8cm}|p{1.2cm}|p{10.3cm}|
> +
> +.. cssclass:: longtable
> +
> +.. flat-table:: Audio Format
> +:header-rows:  1
> +:stub-columns: 0
> +:widths:   3 1 4
> +
> +* - Identifier
> +  - Code
> +  - Details
> +* .. _V4L2-AUDIO-FMT-S8:
> +
> +  - ``V4L2_AUDIO_FMT_S8``
> +  - 'S8'
> +  - Corresponds to SNDRV_PCM_FORMAT_S8 in ALSA
> +* .. _V4L2-AUDIO-FMT-S16-LE:

Hmm... why can't we just use SNDRV_*_FORMAT_*? Those are already part of
an uAPI header. No need to add any abstraction here and/or redefine
what is there already at include/uapi/sound/asound.h.

Thanks,
Mauro


Re: [PATCH 16/22] dvb-usb: Replace comments with C99 initializers

2022-03-26 Thread Mauro Carvalho Chehab
Em Sat, 26 Mar 2022 15:11:46 -0500
Larry Finger  escreveu:

> On 3/26/22 14:51, Joe Perches wrote:
> > On Sat, 2022-03-26 at 19:27 +0100, Mauro Carvalho Chehab wrote:  
> >> Em Sat, 26 Mar 2022 19:24:54 +0100
> >> Mauro Carvalho Chehab  escreveu:
> >>  
> >>> Em Sat, 26 Mar 2022 17:59:03 +0100
> >>> Benjamin Stürz  escreveu:
> >>>  
> >>>> This replaces comments with C99's designated
> >>>> initializers because the kernel supports them now.
> >>>>
> >>>> Signed-off-by: Benjamin Stürz 
> >>>> ---
> >>>>   drivers/media/usb/dvb-usb/dibusb-mb.c | 62 +--
> >>>>   drivers/media/usb/dvb-usb/dibusb-mc.c | 34 +++
> >>>>   2 files changed, 48 insertions(+), 48 deletions(-)
> >>>>
> >>>> diff --git a/drivers/media/usb/dvb-usb/dibusb-mb.c 
> >>>> b/drivers/media/usb/dvb-usb/dibusb-mb.c
> >>>> index e9dc27f73970..f188e07f518b 100644
> >>>> --- a/drivers/media/usb/dvb-usb/dibusb-mb.c
> >>>> +++ b/drivers/media/usb/dvb-usb/dibusb-mb.c
> >>>> @@ -122,40 +122,40 @@ static int dibusb_probe(struct usb_interface *intf,
> >>>>   
> >>>>   /* do not change the order of the ID table */
> >>>>   static struct usb_device_id dibusb_dib3000mb_table [] = {
> >>>> -/* 00 */{ USB_DEVICE(USB_VID_WIDEVIEW,  
> >>>> USB_PID_AVERMEDIA_DVBT_USB_COLD) },
> >>>> -/* 01 */{ USB_DEVICE(USB_VID_WIDEVIEW,  
> >>>> USB_PID_AVERMEDIA_DVBT_USB_WARM) },
> >>>> -/* 02 */{ USB_DEVICE(USB_VID_COMPRO,
> >>>> USB_PID_COMPRO_DVBU2000_COLD) },
> >>>> -/* 03 */{ USB_DEVICE(USB_VID_COMPRO,
> >>>> USB_PID_COMPRO_DVBU2000_WARM) },
> >>>> -/* 04 */{ USB_DEVICE(USB_VID_COMPRO_UNK,
> >>>> USB_PID_COMPRO_DVBU2000_UNK_COLD) },
> >>>> -/* 05 */{ USB_DEVICE(USB_VID_DIBCOM,
> >>>> USB_PID_DIBCOM_MOD3000_COLD) },
> >>>> -/* 06 */{ USB_DEVICE(USB_VID_DIBCOM,
> >>>> USB_PID_DIBCOM_MOD3000_WARM) },
> >>>> -/* 07 */{ USB_DEVICE(USB_VID_EMPIA, 
> >>>> USB_PID_KWORLD_VSTREAM_COLD) },
> >>>> -/* 08 */{ USB_DEVICE(USB_VID_EMPIA, 
> >>>> USB_PID_KWORLD_VSTREAM_WARM) },
> >>>> -/* 09 */{ USB_DEVICE(USB_VID_GRANDTEC,  
> >>>> USB_PID_GRANDTEC_DVBT_USB_COLD) },
> >>>> -/* 10 */{ USB_DEVICE(USB_VID_GRANDTEC,  
> >>>> USB_PID_GRANDTEC_DVBT_USB_WARM) },
> >>>> -/* 11 */{ USB_DEVICE(USB_VID_GRANDTEC,  
> >>>> USB_PID_DIBCOM_MOD3000_COLD) },
> >>>> -/* 12 */{ USB_DEVICE(USB_VID_GRANDTEC,  
> >>>> USB_PID_DIBCOM_MOD3000_WARM) },
> >>>> -/* 13 */{ USB_DEVICE(USB_VID_HYPER_PALTEK,  
> >>>> USB_PID_UNK_HYPER_PALTEK_COLD) },
> >>>> -/* 14 */{ USB_DEVICE(USB_VID_HYPER_PALTEK,  
> >>>> USB_PID_UNK_HYPER_PALTEK_WARM) },
> >>>> -/* 15 */{ USB_DEVICE(USB_VID_VISIONPLUS,
> >>>> USB_PID_TWINHAN_VP7041_COLD) },
> >>>> -/* 16 */{ USB_DEVICE(USB_VID_VISIONPLUS,
> >>>> USB_PID_TWINHAN_VP7041_WARM) },
> >>>> -/* 17 */{ USB_DEVICE(USB_VID_TWINHAN,   
> >>>> USB_PID_TWINHAN_VP7041_COLD) },
> >>>> -/* 18 */{ USB_DEVICE(USB_VID_TWINHAN,   
> >>>> USB_PID_TWINHAN_VP7041_WARM) },
> >>>> -/* 19 */{ USB_DEVICE(USB_VID_ULTIMA_ELECTRONIC, 
> >>>> USB_PID_ULTIMA_TVBOX_COLD) },
> >>>> -/* 20 */{ USB_DEVICE(USB_VID_ULTIMA_ELECTRONIC, 
> >>>> USB_PID_ULTIMA_TVBOX_WARM) },
> >>>> -/* 21 */{ USB_DEVICE(USB_VID_ULTIMA_ELECTRONIC, 
> >>>> USB_PID_ULTIMA_TVBOX_AN2235_COLD) },
> >>>> -/* 22 */{ USB_DEVICE(USB_VID_ULTIMA_ELECTRONIC, 
> >>>> USB_PID_ULTIMA_TVBOX_AN2235_WARM) },
> >>>> -/* 23 */{ USB_DEVICE(USB_VID_ADSTECH,   
> >>>> USB_PID_ADSTECH_USB2_COLD) },
> >>>> +[0]  =  { USB_DEVICE(USB_VID_WIDEVIEW,  
> >>>> USB_PID_AVERMEDIA_DVBT_USB_COLD) },
> >>>> +[1]  =  { USB_DEVICE(USB_VID_WIDEVIEW,  
> >>>> 

Re: [PATCH 16/22] dvb-usb: Replace comments with C99 initializers

2022-03-26 Thread Mauro Carvalho Chehab
Em Sat, 26 Mar 2022 19:24:54 +0100
Mauro Carvalho Chehab  escreveu:

> Em Sat, 26 Mar 2022 17:59:03 +0100
> Benjamin Stürz  escreveu:
> 
> > This replaces comments with C99's designated
> > initializers because the kernel supports them now.
> > 
> > Signed-off-by: Benjamin Stürz 
> > ---
> >  drivers/media/usb/dvb-usb/dibusb-mb.c | 62 +--
> >  drivers/media/usb/dvb-usb/dibusb-mc.c | 34 +++
> >  2 files changed, 48 insertions(+), 48 deletions(-)
> > 
> > diff --git a/drivers/media/usb/dvb-usb/dibusb-mb.c 
> > b/drivers/media/usb/dvb-usb/dibusb-mb.c
> > index e9dc27f73970..f188e07f518b 100644
> > --- a/drivers/media/usb/dvb-usb/dibusb-mb.c
> > +++ b/drivers/media/usb/dvb-usb/dibusb-mb.c
> > @@ -122,40 +122,40 @@ static int dibusb_probe(struct usb_interface *intf,
> >  
> >  /* do not change the order of the ID table */
> >  static struct usb_device_id dibusb_dib3000mb_table [] = {
> > -/* 00 */   { USB_DEVICE(USB_VID_WIDEVIEW,  
> > USB_PID_AVERMEDIA_DVBT_USB_COLD) },
> > -/* 01 */   { USB_DEVICE(USB_VID_WIDEVIEW,  
> > USB_PID_AVERMEDIA_DVBT_USB_WARM) },
> > -/* 02 */   { USB_DEVICE(USB_VID_COMPRO,
> > USB_PID_COMPRO_DVBU2000_COLD) },
> > -/* 03 */   { USB_DEVICE(USB_VID_COMPRO,
> > USB_PID_COMPRO_DVBU2000_WARM) },
> > -/* 04 */   { USB_DEVICE(USB_VID_COMPRO_UNK,
> > USB_PID_COMPRO_DVBU2000_UNK_COLD) },
> > -/* 05 */   { USB_DEVICE(USB_VID_DIBCOM,
> > USB_PID_DIBCOM_MOD3000_COLD) },
> > -/* 06 */   { USB_DEVICE(USB_VID_DIBCOM,
> > USB_PID_DIBCOM_MOD3000_WARM) },
> > -/* 07 */   { USB_DEVICE(USB_VID_EMPIA, 
> > USB_PID_KWORLD_VSTREAM_COLD) },
> > -/* 08 */   { USB_DEVICE(USB_VID_EMPIA, 
> > USB_PID_KWORLD_VSTREAM_WARM) },
> > -/* 09 */   { USB_DEVICE(USB_VID_GRANDTEC,  
> > USB_PID_GRANDTEC_DVBT_USB_COLD) },
> > -/* 10 */   { USB_DEVICE(USB_VID_GRANDTEC,  
> > USB_PID_GRANDTEC_DVBT_USB_WARM) },
> > -/* 11 */   { USB_DEVICE(USB_VID_GRANDTEC,  
> > USB_PID_DIBCOM_MOD3000_COLD) },
> > -/* 12 */   { USB_DEVICE(USB_VID_GRANDTEC,  
> > USB_PID_DIBCOM_MOD3000_WARM) },
> > -/* 13 */   { USB_DEVICE(USB_VID_HYPER_PALTEK,  
> > USB_PID_UNK_HYPER_PALTEK_COLD) },
> > -/* 14 */   { USB_DEVICE(USB_VID_HYPER_PALTEK,  
> > USB_PID_UNK_HYPER_PALTEK_WARM) },
> > -/* 15 */   { USB_DEVICE(USB_VID_VISIONPLUS,
> > USB_PID_TWINHAN_VP7041_COLD) },
> > -/* 16 */   { USB_DEVICE(USB_VID_VISIONPLUS,
> > USB_PID_TWINHAN_VP7041_WARM) },
> > -/* 17 */   { USB_DEVICE(USB_VID_TWINHAN,   
> > USB_PID_TWINHAN_VP7041_COLD) },
> > -/* 18 */   { USB_DEVICE(USB_VID_TWINHAN,   
> > USB_PID_TWINHAN_VP7041_WARM) },
> > -/* 19 */   { USB_DEVICE(USB_VID_ULTIMA_ELECTRONIC, 
> > USB_PID_ULTIMA_TVBOX_COLD) },
> > -/* 20 */   { USB_DEVICE(USB_VID_ULTIMA_ELECTRONIC, 
> > USB_PID_ULTIMA_TVBOX_WARM) },
> > -/* 21 */   { USB_DEVICE(USB_VID_ULTIMA_ELECTRONIC, 
> > USB_PID_ULTIMA_TVBOX_AN2235_COLD) },
> > -/* 22 */   { USB_DEVICE(USB_VID_ULTIMA_ELECTRONIC, 
> > USB_PID_ULTIMA_TVBOX_AN2235_WARM) },
> > -/* 23 */   { USB_DEVICE(USB_VID_ADSTECH,   
> > USB_PID_ADSTECH_USB2_COLD) },
> > +[0]  = { USB_DEVICE(USB_VID_WIDEVIEW,  
> > USB_PID_AVERMEDIA_DVBT_USB_COLD) },
> > +[1]  = { USB_DEVICE(USB_VID_WIDEVIEW,  
> > USB_PID_AVERMEDIA_DVBT_USB_WARM) },  
> 
> While here, please properly indent this table, and respect the 80-columns 
> limit,
> e. g.:
> 
> static struct usb_device_id dibusb_dib3000mb_table [] = {
>   [0] = { USB_DEVICE(USB_VID_WIDEVIEW 
>  USB_PID_AVERMEDIA_DVBT_USB_COLD) 
>   },
>   [1]  =  { USB_DEVICE(USB_VID_WIDEVIEW,
>USB_PID_AVERMEDIA_DVBT_USB_WARM)
>   },
>   ...

Err something went wrong with my space bar and I ended hitting send to
soon... I meant:

static struct usb_device_id dibusb_dib3000mb_table [] = {
[0] = { USB_DEVICE(USB_VID_WIDEVIEW 
   USB_PID_AVERMEDIA_DVBT_USB_COLD) 
},
[1] = { USB_DEVICE(USB_VID_WIDEVIEW,
   USB_PID_AVERMEDIA_DVBT_USB_WARM)
},
...
};

Thanks,
Mauro


Re: [PATCH 16/22] dvb-usb: Replace comments with C99 initializers

2022-03-26 Thread Mauro Carvalho Chehab
Em Sat, 26 Mar 2022 17:59:03 +0100
Benjamin Stürz  escreveu:

> This replaces comments with C99's designated
> initializers because the kernel supports them now.
> 
> Signed-off-by: Benjamin Stürz 
> ---
>  drivers/media/usb/dvb-usb/dibusb-mb.c | 62 +--
>  drivers/media/usb/dvb-usb/dibusb-mc.c | 34 +++
>  2 files changed, 48 insertions(+), 48 deletions(-)
> 
> diff --git a/drivers/media/usb/dvb-usb/dibusb-mb.c 
> b/drivers/media/usb/dvb-usb/dibusb-mb.c
> index e9dc27f73970..f188e07f518b 100644
> --- a/drivers/media/usb/dvb-usb/dibusb-mb.c
> +++ b/drivers/media/usb/dvb-usb/dibusb-mb.c
> @@ -122,40 +122,40 @@ static int dibusb_probe(struct usb_interface *intf,
>  
>  /* do not change the order of the ID table */
>  static struct usb_device_id dibusb_dib3000mb_table [] = {
> -/* 00 */ { USB_DEVICE(USB_VID_WIDEVIEW,  
> USB_PID_AVERMEDIA_DVBT_USB_COLD) },
> -/* 01 */ { USB_DEVICE(USB_VID_WIDEVIEW,  
> USB_PID_AVERMEDIA_DVBT_USB_WARM) },
> -/* 02 */ { USB_DEVICE(USB_VID_COMPRO,
> USB_PID_COMPRO_DVBU2000_COLD) },
> -/* 03 */ { USB_DEVICE(USB_VID_COMPRO,
> USB_PID_COMPRO_DVBU2000_WARM) },
> -/* 04 */ { USB_DEVICE(USB_VID_COMPRO_UNK,
> USB_PID_COMPRO_DVBU2000_UNK_COLD) },
> -/* 05 */ { USB_DEVICE(USB_VID_DIBCOM,
> USB_PID_DIBCOM_MOD3000_COLD) },
> -/* 06 */ { USB_DEVICE(USB_VID_DIBCOM,
> USB_PID_DIBCOM_MOD3000_WARM) },
> -/* 07 */ { USB_DEVICE(USB_VID_EMPIA, 
> USB_PID_KWORLD_VSTREAM_COLD) },
> -/* 08 */ { USB_DEVICE(USB_VID_EMPIA, 
> USB_PID_KWORLD_VSTREAM_WARM) },
> -/* 09 */ { USB_DEVICE(USB_VID_GRANDTEC,  
> USB_PID_GRANDTEC_DVBT_USB_COLD) },
> -/* 10 */ { USB_DEVICE(USB_VID_GRANDTEC,  
> USB_PID_GRANDTEC_DVBT_USB_WARM) },
> -/* 11 */ { USB_DEVICE(USB_VID_GRANDTEC,  
> USB_PID_DIBCOM_MOD3000_COLD) },
> -/* 12 */ { USB_DEVICE(USB_VID_GRANDTEC,  
> USB_PID_DIBCOM_MOD3000_WARM) },
> -/* 13 */ { USB_DEVICE(USB_VID_HYPER_PALTEK,  
> USB_PID_UNK_HYPER_PALTEK_COLD) },
> -/* 14 */ { USB_DEVICE(USB_VID_HYPER_PALTEK,  
> USB_PID_UNK_HYPER_PALTEK_WARM) },
> -/* 15 */ { USB_DEVICE(USB_VID_VISIONPLUS,
> USB_PID_TWINHAN_VP7041_COLD) },
> -/* 16 */ { USB_DEVICE(USB_VID_VISIONPLUS,
> USB_PID_TWINHAN_VP7041_WARM) },
> -/* 17 */ { USB_DEVICE(USB_VID_TWINHAN,   
> USB_PID_TWINHAN_VP7041_COLD) },
> -/* 18 */ { USB_DEVICE(USB_VID_TWINHAN,   
> USB_PID_TWINHAN_VP7041_WARM) },
> -/* 19 */ { USB_DEVICE(USB_VID_ULTIMA_ELECTRONIC, 
> USB_PID_ULTIMA_TVBOX_COLD) },
> -/* 20 */ { USB_DEVICE(USB_VID_ULTIMA_ELECTRONIC, 
> USB_PID_ULTIMA_TVBOX_WARM) },
> -/* 21 */ { USB_DEVICE(USB_VID_ULTIMA_ELECTRONIC, 
> USB_PID_ULTIMA_TVBOX_AN2235_COLD) },
> -/* 22 */ { USB_DEVICE(USB_VID_ULTIMA_ELECTRONIC, 
> USB_PID_ULTIMA_TVBOX_AN2235_WARM) },
> -/* 23 */ { USB_DEVICE(USB_VID_ADSTECH,   
> USB_PID_ADSTECH_USB2_COLD) },
> +[0]  =   { USB_DEVICE(USB_VID_WIDEVIEW,  
> USB_PID_AVERMEDIA_DVBT_USB_COLD) },
> +[1]  =   { USB_DEVICE(USB_VID_WIDEVIEW,  
> USB_PID_AVERMEDIA_DVBT_USB_WARM) },

While here, please properly indent this table, and respect the 80-columns limit,
e. g.:

static struct usb_device_id dibusb_dib3000mb_table [] = {
[0] = { USB_DEVICE(USB_VID_WIDEVIEW 
   USB_PID_AVERMEDIA_DVBT_USB_COLD) 
},
[1]  =  { USB_DEVICE(USB_VID_WIDEVIEW,
 USB_PID_AVERMEDIA_DVBT_USB_WARM)
},
...


Regards,
Mauro

> +[2]  =   { USB_DEVICE(USB_VID_COMPRO,
> USB_PID_COMPRO_DVBU2000_COLD) },
> +[3]  =   { USB_DEVICE(USB_VID_COMPRO,
> USB_PID_COMPRO_DVBU2000_WARM) },
> +[4]  =   { USB_DEVICE(USB_VID_COMPRO_UNK,
> USB_PID_COMPRO_DVBU2000_UNK_COLD) },
> +[5]  =   { USB_DEVICE(USB_VID_DIBCOM,
> USB_PID_DIBCOM_MOD3000_COLD) },
> +[6]  =   { USB_DEVICE(USB_VID_DIBCOM,
> USB_PID_DIBCOM_MOD3000_WARM) },
> +[7]  =   { USB_DEVICE(USB_VID_EMPIA, 
> USB_PID_KWORLD_VSTREAM_COLD) },
> +[8]  =   { USB_DEVICE(USB_VID_EMPIA, 
> USB_PID_KWORLD_VSTREAM_WARM) },
> +[9]  =   { USB_DEVICE(USB_VID_GRANDTEC,  
> USB_PID_GRANDTEC_DVBT_USB_COLD) },
> +[10] =   { USB_DEVICE(USB_VID_GRANDTEC,  
> USB_PID_GRANDTEC_DVBT_USB_WARM) },
> +[11] =   { USB_DEVICE(USB_VID_GRANDTEC,  
> USB_PID_DIBCOM_MOD3000_COLD) },
> +[12] =   { USB_DEVICE(USB_VID_GRANDTEC,  
> USB_PID_DIBCOM_MOD3000_WARM) },
> +[13] =   { USB_DEVICE(USB_VID_HYPER_PALTEK,  
> USB_PID_UNK_HYPER_PALTEK_COLD) },
> +[14] =   { USB_DEVICE(USB_VID_HYPER_PALTEK,  
> USB_PID_UNK_HYPER_PALTEK_WARM) },
> +[15] =   { USB_DEVICE(USB_VID_VISIONPLUS,
> USB_PID_TWINHAN_VP7041_COLD) },
> +[16] =   { USB_DEVICE(USB_VID_VISIONPLUS,
> 

Re: [PATCH 01/22] orion5x: Replace comments with C99 initializers

2022-03-26 Thread Mauro Carvalho Chehab
Em Sat, 26 Mar 2022 17:58:48 +0100
Benjamin Stürz  escreveu:

> This replaces comments with C99's designated
> initializers because the kernel supports them now.

Please:

1. Split this series per sub-system. It makes no sense to mailbomb all
   subsystems for things that won't belong there;

2. Add a patch 00 to the series, in order to make easier to do reviews
   like this that are meant to the series as a hole.

Regards,
Mauro
> 
> Signed-off-by: Benjamin Stürz 
> ---
>  arch/arm/mach-orion5x/dns323-setup.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/arch/arm/mach-orion5x/dns323-setup.c 
> b/arch/arm/mach-orion5x/dns323-setup.c
> index 87cb47220e82..d762248c6512 100644
> --- a/arch/arm/mach-orion5x/dns323-setup.c
> +++ b/arch/arm/mach-orion5x/dns323-setup.c
> @@ -61,9 +61,9 @@
>  
>  /* Exposed to userspace, do not change */
>  enum {
> - DNS323_REV_A1,  /* 0 */
> - DNS323_REV_B1,  /* 1 */
> - DNS323_REV_C1,  /* 2 */
> + DNS323_REV_A1 = 0,
> + DNS323_REV_B1 = 1,
> + DNS323_REV_C1 = 2,
>  };
>  
>  



Thanks,
Mauro


Re: [RFC 02/32] Kconfig: introduce HAS_IOPORT option and select it as necessary

2021-12-29 Thread Mauro Carvalho Chehab
Em Mon, 27 Dec 2021 17:42:47 +0100
Niklas Schnelle  escreveu:

> We introduce a new HAS_IOPORT Kconfig option to gate support for
> I/O port access. In a future patch HAS_IOPORT=n will disable compilation
> of the I/O accessor functions inb()/outb() and friends on architectures
> which can not meaningfully support legacy I/O spaces. On these platforms
> inb()/outb() etc are currently just stubs in asm-generic/io.h which when
> called will cause a NULL pointer access which some compilers actually
> detect and warn about.
> 
> The dependencies on HAS_IOPORT in drivers as well as ifdefs for
> HAS_IOPORT specific sections will be added in subsequent patches on
> a per subsystem basis. Then a final patch will ifdef the I/O access
> functions on HAS_IOPORT thus turning any use not gated by HAS_IOPORT
> into a compile-time warning.
> 
> Link: 
> https://lore.kernel.org/lkml/CAHk-=wg80je=k7madf4e7wrrnp37e3qh6y10svhdc7o8sz_...@mail.gmail.com/
> Co-developed-by: Arnd Bergmann 
> Signed-off-by: Arnd Bergmann 
> Signed-off-by: Niklas Schnelle 

...

> @@ -486,6 +487,9 @@ config HAS_IOMEM
>   depends on !NO_IOMEM
>   default y
>  
> +config HAS_IOPORT
> + def_bool ISA || LEGACY_PCI
> +

That doesn't sound right. 

The only dependency for LEGACY_PCI is PCI. If one selects LEGACY_PCI
on an architecture that doesn't support it, this will cause problems.

Instead, HAS_IOPORT should be selected at architecture level, and
the dependency here should be just the opposite: LEGACY_API should
depends on HAS_IOPORT.

Thanks,
Mauro


Re: [PATCH] docs: typo fixes in Documentation/ABI/

2021-10-06 Thread Mauro Carvalho Chehab
Em Wed,  6 Oct 2021 14:13:25 +0200
Sohaib Mohamed  escreveu:

> Signed-off-by: Sohaib Mohamed 

Please add a description for the patch, explaining what typo issues you
fixed. The patch itself looks sane to me.


> ---
>  Documentation/ABI/stable/sysfs-module | 2 +-
>  Documentation/ABI/testing/sysfs-bus-rapidio   | 2 +-
>  Documentation/ABI/testing/sysfs-class-cxl | 4 ++--
>  Documentation/ABI/testing/sysfs-class-rnbd-client | 2 +-
>  Documentation/ABI/testing/sysfs-class-rtrs-client | 2 +-
>  Documentation/ABI/testing/sysfs-class-rtrs-server | 2 +-
>  Documentation/ABI/testing/sysfs-devices-platform-ACPI-TAD | 2 +-
>  Documentation/ABI/testing/sysfs-devices-power | 2 +-
>  Documentation/ABI/testing/sysfs-driver-ufs| 2 +-
>  Documentation/ABI/testing/sysfs-firmware-acpi | 2 +-
>  10 files changed, 11 insertions(+), 11 deletions(-)
> 
> diff --git a/Documentation/ABI/stable/sysfs-module 
> b/Documentation/ABI/stable/sysfs-module
> index 560b4a3278df..41b1f16e8795 100644
> --- a/Documentation/ABI/stable/sysfs-module
> +++ b/Documentation/ABI/stable/sysfs-module
> @@ -38,7 +38,7 @@ What:   /sys/module//srcversion
>  Date:Jun 2005
>  Description:
>   If the module source has MODULE_VERSION, this file will contain
> - the checksum of the the source code.
> + the checksum of the source code.
>  
>  What:/sys/module//version
>  Date:Jun 2005
> diff --git a/Documentation/ABI/testing/sysfs-bus-rapidio 
> b/Documentation/ABI/testing/sysfs-bus-rapidio
> index f8b6728dac10..9e8fbff99b75 100644
> --- a/Documentation/ABI/testing/sysfs-bus-rapidio
> +++ b/Documentation/ABI/testing/sysfs-bus-rapidio
> @@ -95,7 +95,7 @@ Contact:Matt Porter ,
>   Alexandre Bounine 
>  Description:
>   (RO) returns name of previous device (switch) on the path to the
> - device that that owns this attribute
> + device that owns this attribute
>  
>  What:/sys/bus/rapidio/devices/::/modalias
>  Date:Jul, 2013
> diff --git a/Documentation/ABI/testing/sysfs-class-cxl 
> b/Documentation/ABI/testing/sysfs-class-cxl
> index 3c77677e0ca7..594fda254130 100644
> --- a/Documentation/ABI/testing/sysfs-class-cxl
> +++ b/Documentation/ABI/testing/sysfs-class-cxl
> @@ -103,8 +103,8 @@ What:   
> /sys/class/cxl//api_version_compatible
>  Date:   September 2014
>  Contact:linuxppc-dev@lists.ozlabs.org
>  Description:read only
> -Decimal value of the the lowest version of the userspace API
> -this this kernel supports.
> +Decimal value of the lowest version of the userspace API
> +this kernel supports.
>  Users:   https://github.com/ibm-capi/libcxl
>  
>  
> diff --git a/Documentation/ABI/testing/sysfs-class-rnbd-client 
> b/Documentation/ABI/testing/sysfs-class-rnbd-client
> index 0b5997ab3365..e6cdc851952c 100644
> --- a/Documentation/ABI/testing/sysfs-class-rnbd-client
> +++ b/Documentation/ABI/testing/sysfs-class-rnbd-client
> @@ -128,6 +128,6 @@ Description:  For each device mapped on the client a 
> new symbolic link is created
>   The  of each device is created as follows:
>  
>   - If the 'device_path' provided during mapping contains slashes 
> ("/"),
> -   they are replaced by exclamation mark ("!") and used as as the
> +   they are replaced by exclamation mark ("!") and used as the
> . Otherwise, the  will be the same as 
> the
> "device_path" provided.
> diff --git a/Documentation/ABI/testing/sysfs-class-rtrs-client 
> b/Documentation/ABI/testing/sysfs-class-rtrs-client
> index 49a4157c7bf1..fecc59d1b96f 100644
> --- a/Documentation/ABI/testing/sysfs-class-rtrs-client
> +++ b/Documentation/ABI/testing/sysfs-class-rtrs-client
> @@ -78,7 +78,7 @@ What:   
> /sys/class/rtrs-client//paths//hca_name
>  Date:Feb 2020
>  KernelVersion:   5.7
>  Contact: Jack Wang  Danil Kipnis 
> 
> -Description: RO, Contains the the name of HCA the connection established on.
> +Description: RO, Contains the name of HCA the connection established on.
>  
>  What:
> /sys/class/rtrs-client//paths//hca_port
>  Date:Feb 2020
> diff --git a/Documentation/ABI/testing/sysfs-class-rtrs-server 
> b/Documentation/ABI/testing/sysfs-class-rtrs-server
> index 3b6d5b067df0..b08601d80409 100644
> --- a/Documentation/ABI/testing/sysfs-class-rtrs-server
> +++ b/Documentation/ABI/testing/sysfs-class-rtrs-server
> @@ -24,7 +24,7 @@ What:   
> /sys/class/rtrs-server//paths//hca_name
>  Date:Feb 2020
>  KernelVersion:   5.7
>  Contact: Jack Wang  Danil Kipnis 
> 
> -Description: RO, Contains the the name of HCA the 

[PATCH v3 07/30] ABI: sysfs-class-cxl: place "not in a guest" at description

2021-09-16 Thread Mauro Carvalho Chehab
The What: field should have just the location of the ABI.
Anything else should be inside the description.

This fixes its parsing by get_abi.pl script.

Acked-by: Andrew Donnellan 
Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/ABI/testing/sysfs-class-cxl | 15 ++-
 1 file changed, 10 insertions(+), 5 deletions(-)

diff --git a/Documentation/ABI/testing/sysfs-class-cxl 
b/Documentation/ABI/testing/sysfs-class-cxl
index 818f55970efb..3c77677e0ca7 100644
--- a/Documentation/ABI/testing/sysfs-class-cxl
+++ b/Documentation/ABI/testing/sysfs-class-cxl
@@ -166,10 +166,11 @@ Description:read only
 Decimal value of the Per Process MMIO space length.
 Users: https://github.com/ibm-capi/libcxl
 
-What:   /sys/class/cxl/m/pp_mmio_off (not in a guest)
+What:   /sys/class/cxl/m/pp_mmio_off
 Date:   September 2014
 Contact:linuxppc-dev@lists.ozlabs.org
 Description:read only
+(not in a guest)
 Decimal value of the Per Process MMIO space offset.
 Users: https://github.com/ibm-capi/libcxl
 
@@ -190,28 +191,31 @@ Description:read only
 Identifies the revision level of the PSL.
 Users: https://github.com/ibm-capi/libcxl
 
-What:   /sys/class/cxl//base_image (not in a guest)
+What:   /sys/class/cxl//base_image
 Date:   September 2014
 Contact:linuxppc-dev@lists.ozlabs.org
 Description:read only
+(not in a guest)
 Identifies the revision level of the base image for devices
 that support loadable PSLs. For FPGAs this field identifies
 the image contained in the on-adapter flash which is loaded
 during the initial program load.
 Users: https://github.com/ibm-capi/libcxl
 
-What:   /sys/class/cxl//image_loaded (not in a guest)
+What:   /sys/class/cxl//image_loaded
 Date:   September 2014
 Contact:linuxppc-dev@lists.ozlabs.org
 Description:read only
+(not in a guest)
 Will return "user" or "factory" depending on the image loaded
 onto the card.
 Users: https://github.com/ibm-capi/libcxl
 
-What:   /sys/class/cxl//load_image_on_perst (not in a guest)
+What:   /sys/class/cxl//load_image_on_perst
 Date:   December 2014
 Contact:linuxppc-dev@lists.ozlabs.org
 Description:read/write
+(not in a guest)
 Valid entries are "none", "user", and "factory".
 "none" means PERST will not cause image to be loaded to the
 card.  A power cycle is required to load the image.
@@ -235,10 +239,11 @@ Description:write only
 contexts on the card AFUs.
 Users: https://github.com/ibm-capi/libcxl
 
-What:  /sys/class/cxl//perst_reloads_same_image (not in a guest)
+What:  /sys/class/cxl//perst_reloads_same_image
 Date:  July 2015
 Contact:   linuxppc-dev@lists.ozlabs.org
 Description:   read/write
+(not in a guest)
Trust that when an image is reloaded via PERST, it will not
have changed.
 
-- 
2.31.1



[PATCH v3 00/30]Change wildcards on ABI files

2021-09-16 Thread Mauro Carvalho Chehab
The ABI files are meant to be parsed via a script (scripts/get_abi.pl).

A new improvement on it will allow it to help to detect if an ABI description
is missing, or if the What: field won't match the actual location of the symbol.

In order for get_abi.pl to convert What: into regex, changes are needed on
existing ABI files, as the conversion should not be ambiguous.

One alternative would be to convert everything into regexes, but this
would generate a huge amount of patches/changes. So, instead, let's
touch only the ABI files that aren't following the de-facto wildcard 
standards already found on most of the ABI files, e. g.:

/.../
*

(option1|option2)
X
Y
Z
[0-9] (and variants)

---

v3:
   - Added a new patch for sysfs-class-rapidio;
   - sysfs-class-typec had a typo, instead of a wildcard;
   - sysfs-bus-soundwire-* had some additional What to be fixed;
   - added some reviewed-by/acked-by tags.

v2:
   - Added several patches to address uppercase "N" meaning
 as a wildcard.

Mauro Carvalho Chehab (30):
  ABI: sysfs-bus-usb: better document variable argument
  ABI: sysfs-tty: better document module name parameter
  ABI: sysfs-kernel-slab: use a wildcard for the cache name
  ABI: security: fix location for evm and ima_policy
  ABI: sysfs-class-tpm: use wildcards for pcr-* nodes
  ABI: sysfs-bus-rapidio: use wildcards on What definitions
  ABI: sysfs-class-cxl: place "not in a guest" at description
  ABI: sysfs-class-devfreq-event: use the right wildcards on What
  ABI: sysfs-class-mic: use the right wildcards on What definitions
  ABI: pstore: Fix What field
  ABI:  fix a typo on a What field
  ABI: sysfs-ata: use a proper wildcard for ata_*
  ABI: sysfs-class-infiniband: use wildcards on What definitions
  ABI: sysfs-bus-pci: use wildcards on What definitions
  ABI: -master: use wildcards on What definitions
  ABI: sysfs-bus-soundwire-slave: use wildcards on What definitions
  ABI: sysfs-class-gnss: use wildcards on What definitions
  ABI: sysfs-class-mei: use wildcards on What definitions
  ABI: sysfs-class-mux: use wildcards on What definitions
  ABI: sysfs-class-pwm: use wildcards on What definitions
  ABI: sysfs-class-rc: use wildcards on What definitions
  ABI: sysfs-class-rc-nuvoton: use wildcards on What definitions
  ABI: sysfs-class-uwb_rc: use wildcards on What definitions
  ABI: sysfs-class-uwb_rc-wusbhc: use wildcards on What definitions
  ABI: sysfs-devices-platform-dock: use wildcards on What definitions
  ABI: sysfs-devices-system-cpu: use wildcards on What definitions
  ABI: sysfs-firmware-efi-esrt: use wildcards on What definitions
  ABI: sysfs-platform-sst-atom: use wildcards on What definitions
  ABI: sysfs-ptp: use wildcards on What definitions
  ABI: sysfs-class-rapidio: use wildcards on What definitions

 .../ABI/stable/sysfs-class-infiniband | 64 ++---
 Documentation/ABI/stable/sysfs-class-tpm  |  2 +-
 Documentation/ABI/testing/evm |  4 +-
 Documentation/ABI/testing/ima_policy  |  2 +-
 Documentation/ABI/testing/pstore  |  3 +-
 Documentation/ABI/testing/sysfs-ata   |  2 +-
 Documentation/ABI/testing/sysfs-bus-pci   |  2 +-
 Documentation/ABI/testing/sysfs-bus-rapidio   | 32 +++
 .../ABI/testing/sysfs-bus-soundwire-master| 20 ++--
 .../ABI/testing/sysfs-bus-soundwire-slave | 60 ++--
 Documentation/ABI/testing/sysfs-bus-usb   | 16 ++--
 Documentation/ABI/testing/sysfs-class-cxl | 15 ++-
 .../ABI/testing/sysfs-class-devfreq-event | 12 +--
 Documentation/ABI/testing/sysfs-class-gnss|  2 +-
 Documentation/ABI/testing/sysfs-class-mei | 18 ++--
 Documentation/ABI/testing/sysfs-class-mic | 24 ++---
 Documentation/ABI/testing/sysfs-class-mux |  2 +-
 Documentation/ABI/testing/sysfs-class-pwm | 20 ++--
 Documentation/ABI/testing/sysfs-class-rapidio |  4 +-
 Documentation/ABI/testing/sysfs-class-rc  | 14 +--
 .../ABI/testing/sysfs-class-rc-nuvoton|  2 +-
 Documentation/ABI/testing/sysfs-class-typec   |  2 +-
 Documentation/ABI/testing/sysfs-class-uwb_rc  | 26 ++---
 .../ABI/testing/sysfs-class-uwb_rc-wusbhc | 10 +-
 .../ABI/testing/sysfs-devices-platform-dock   | 10 +-
 .../ABI/testing/sysfs-devices-system-cpu  | 16 ++--
 .../ABI/testing/sysfs-firmware-efi-esrt   | 16 ++--
 Documentation/ABI/testing/sysfs-kernel-slab   | 94 +--
 .../ABI/testing/sysfs-platform-sst-atom   |  2 +-
 Documentation/ABI/testing/sysfs-ptp   | 30 +++---
 Documentation/ABI/testing/sysfs-tty   | 32 +++
 31 files changed, 282 insertions(+), 276 deletions(-)

-- 
2.31.1




[PATCH v2 07/29] ABI: sysfs-class-cxl: place "not in a guest" at description

2021-09-14 Thread Mauro Carvalho Chehab
The What: field should have just the location of the ABI.
Anything else should be inside the description.

This fixes its parsing by get_abi.pl script.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/ABI/testing/sysfs-class-cxl | 15 ++-
 1 file changed, 10 insertions(+), 5 deletions(-)

diff --git a/Documentation/ABI/testing/sysfs-class-cxl 
b/Documentation/ABI/testing/sysfs-class-cxl
index 818f55970efb..3c77677e0ca7 100644
--- a/Documentation/ABI/testing/sysfs-class-cxl
+++ b/Documentation/ABI/testing/sysfs-class-cxl
@@ -166,10 +166,11 @@ Description:read only
 Decimal value of the Per Process MMIO space length.
 Users: https://github.com/ibm-capi/libcxl
 
-What:   /sys/class/cxl/m/pp_mmio_off (not in a guest)
+What:   /sys/class/cxl/m/pp_mmio_off
 Date:   September 2014
 Contact:linuxppc-dev@lists.ozlabs.org
 Description:read only
+(not in a guest)
 Decimal value of the Per Process MMIO space offset.
 Users: https://github.com/ibm-capi/libcxl
 
@@ -190,28 +191,31 @@ Description:read only
 Identifies the revision level of the PSL.
 Users: https://github.com/ibm-capi/libcxl
 
-What:   /sys/class/cxl//base_image (not in a guest)
+What:   /sys/class/cxl//base_image
 Date:   September 2014
 Contact:linuxppc-dev@lists.ozlabs.org
 Description:read only
+(not in a guest)
 Identifies the revision level of the base image for devices
 that support loadable PSLs. For FPGAs this field identifies
 the image contained in the on-adapter flash which is loaded
 during the initial program load.
 Users: https://github.com/ibm-capi/libcxl
 
-What:   /sys/class/cxl//image_loaded (not in a guest)
+What:   /sys/class/cxl//image_loaded
 Date:   September 2014
 Contact:linuxppc-dev@lists.ozlabs.org
 Description:read only
+(not in a guest)
 Will return "user" or "factory" depending on the image loaded
 onto the card.
 Users: https://github.com/ibm-capi/libcxl
 
-What:   /sys/class/cxl//load_image_on_perst (not in a guest)
+What:   /sys/class/cxl//load_image_on_perst
 Date:   December 2014
 Contact:linuxppc-dev@lists.ozlabs.org
 Description:read/write
+(not in a guest)
 Valid entries are "none", "user", and "factory".
 "none" means PERST will not cause image to be loaded to the
 card.  A power cycle is required to load the image.
@@ -235,10 +239,11 @@ Description:write only
 contexts on the card AFUs.
 Users: https://github.com/ibm-capi/libcxl
 
-What:  /sys/class/cxl//perst_reloads_same_image (not in a guest)
+What:  /sys/class/cxl//perst_reloads_same_image
 Date:  July 2015
 Contact:   linuxppc-dev@lists.ozlabs.org
 Description:   read/write
+(not in a guest)
Trust that when an image is reloaded via PERST, it will not
have changed.
 
-- 
2.31.1



[PATCH v2 00/29] Change wildcards on ABI files

2021-09-14 Thread Mauro Carvalho Chehab
The ABI files are meant to be parsed via a script (scripts/get_abi.pl).

A new improvement on it will allow it to help to detect if an ABI description
is missing, or if the What: field won't match the actual location of the symbol.

In order for get_abi.pl to convert What: into regex, changes are needed on
existing ABI files, as the conversion should not be ambiguous.

One alternative would be to convert everything into regexes, but this
would generate a huge amount of patches/changes. So, instead, let's
touch only the ABI files that aren't following the de-facto wildcard 
standards already found on most of the ABI files, e. g.:

/.../
*

(option1|option2)
X
Y
Z
[0-9] (and variants)

A couple of the patches here came from v1, but most of the patches were
written to address things like rcN, where N is a wildcard.

We can't teach get_abi.pl to use an uppercase "N" letter to be a wildcard,
as the USB ABI already uses "N" inside some of their symbols, like 
bNumEndpoints.

Mauro Carvalho Chehab (29):
  ABI: sysfs-bus-usb: better document variable argument
  ABI: sysfs-tty: better document module name parameter
  ABI: sysfs-kernel-slab: use a wildcard for the cache name
  ABI: security: fix location for evm and ima_policy
  ABI: sysfs-class-tpm: use wildcards for pcr-* nodes
  ABI: sysfs-bus-rapidio: use wildcards on What definitions
  ABI: sysfs-class-cxl: place "not in a guest" at description
  ABI: sysfs-class-devfreq-event: use the right wildcards on What
  ABI: sysfs-class-mic: use the right wildcards on What definitions
  ABI: pstore: Fix What field
  ABI: sysfs-class-typec: fix a bad What field
  ABI: sysfs-ata: use a proper wildcard for ata_*
  ABI: sysfs-class-infiniband: use wildcards on What definitions
  ABI: sysfs-bus-pci: use wildcards on What definitions
  ABI: sysfs-bus-soundwire-master: use wildcards on What definitions
  ABI: sysfs-bus-soundwire-slave: use wildcards on What definitions
  ABI: sysfs-class-gnss: use wildcards on What definitions
  ABI: sysfs-class-mei: use wildcards on What definitions
  ABI: sysfs-class-mux: use wildcards on What definitions
  ABI: sysfs-class-pwm: use wildcards on What definitions
  ABI: sysfs-class-rc: use wildcards on What definitions
  ABI: sysfs-class-rc-nuvoton: use wildcards on What definitions
  ABI: sysfs-class-uwb_rc: use wildcards on What definitions
  ABI: sysfs-class-uwb_rc-wusbhc: use wildcards on What definitions
  ABI: sysfs-devices-platform-dock: use wildcards on What definitions
  ABI: sysfs-devices-system-cpu: use wildcards on What definitions
  ABI: sysfs-firmware-efi-esrt: use wildcards on What definitions
  ABI: sysfs-platform-sst-atom: use wildcards on What definitions
  ABI: sysfs-ptp: use wildcards on What definitions

 .../ABI/stable/sysfs-class-infiniband | 64 ++---
 Documentation/ABI/stable/sysfs-class-tpm  |  2 +-
 Documentation/ABI/testing/evm |  4 +-
 Documentation/ABI/testing/ima_policy  |  2 +-
 Documentation/ABI/testing/pstore  |  3 +-
 Documentation/ABI/testing/sysfs-ata   |  2 +-
 Documentation/ABI/testing/sysfs-bus-pci   |  2 +-
 Documentation/ABI/testing/sysfs-bus-rapidio   | 32 +++
 .../ABI/testing/sysfs-bus-soundwire-master|  2 +-
 .../ABI/testing/sysfs-bus-soundwire-slave |  2 +-
 Documentation/ABI/testing/sysfs-bus-usb   | 16 ++--
 Documentation/ABI/testing/sysfs-class-cxl | 15 ++-
 .../ABI/testing/sysfs-class-devfreq-event | 12 +--
 Documentation/ABI/testing/sysfs-class-gnss|  2 +-
 Documentation/ABI/testing/sysfs-class-mei | 18 ++--
 Documentation/ABI/testing/sysfs-class-mic | 24 ++---
 Documentation/ABI/testing/sysfs-class-mux |  2 +-
 Documentation/ABI/testing/sysfs-class-pwm | 20 ++--
 Documentation/ABI/testing/sysfs-class-rc  | 14 +--
 .../ABI/testing/sysfs-class-rc-nuvoton|  2 +-
 Documentation/ABI/testing/sysfs-class-typec   |  2 +-
 Documentation/ABI/testing/sysfs-class-uwb_rc  | 26 ++---
 .../ABI/testing/sysfs-class-uwb_rc-wusbhc | 10 +-
 .../ABI/testing/sysfs-devices-platform-dock   | 10 +-
 .../ABI/testing/sysfs-devices-system-cpu  | 16 ++--
 .../ABI/testing/sysfs-firmware-efi-esrt   | 16 ++--
 Documentation/ABI/testing/sysfs-kernel-slab   | 94 +--
 .../ABI/testing/sysfs-platform-sst-atom   |  2 +-
 Documentation/ABI/testing/sysfs-ptp   | 30 +++---
 Documentation/ABI/testing/sysfs-tty   | 32 +++
 30 files changed, 242 insertions(+), 236 deletions(-)

-- 
2.31.1




Re: [PATCH] bus: Make remove callback return void

2021-07-06 Thread Mauro Carvalho Chehab
Em Tue,  6 Jul 2021 11:50:37 +0200
Uwe Kleine-König  escreveu:

> The driver core ignores the return value of this callback because there
> is only little it can do when a device disappears.
> 
> This is the final bit of a long lasting cleanup quest where several
> buses were converted to also return void from their remove callback.
> Additionally some resource leaks were fixed that were caused by drivers
> returning an error code in the expectation that the driver won't go
> away.
> 
> With struct bus_type::remove returning void it's prevented that newly
> implemented buses return an ignored error code and so don't anticipate
> wrong expectations for driver authors.
> 
> Signed-off-by: Uwe Kleine-König 
> ---
> Hello,
> 
> this patch depends on "PCI: endpoint: Make struct pci_epf_driver::remove
> return void" that is not yet applied, see
> https://lore.kernel.org/r/20210223090757.57604-1-u.kleine-koe...@pengutronix.de.
> 
> I tested it using allmodconfig on amd64 and arm, but I wouldn't be
> surprised if I still missed to convert a driver. So it would be great to
> get this into next early after the merge window closes.
> 
> I send this mail to all people that get_maintainer.pl emits for this
> patch. I wonder how many recipents will refuse this mail because of the
> long Cc: list :-)
> 
> Best regards
> Uwe
> 

> diff --git a/drivers/media/pci/bt8xx/bttv-gpio.c 
> b/drivers/media/pci/bt8xx/bttv-gpio.c
> index b730225ca887..a2b18e2bed1b 100644
> --- a/drivers/media/pci/bt8xx/bttv-gpio.c
> +++ b/drivers/media/pci/bt8xx/bttv-gpio.c
> @@ -46,14 +46,13 @@ static int bttv_sub_probe(struct device *dev)
>   return sub->probe ? sub->probe(sdev) : -ENODEV;
>  }
>  
> -static int bttv_sub_remove(struct device *dev)
> +static void bttv_sub_remove(struct device *dev)
>  {
>   struct bttv_sub_device *sdev = to_bttv_sub_dev(dev);
>   struct bttv_sub_driver *sub = to_bttv_sub_drv(dev->driver);
>  
>   if (sub->remove)
>   sub->remove(sdev);
> - return 0;
>  }
>  

Acked-by: Mauro Carvalho Chehab  # for drivers/media


Thanks,
Mauro


[PATCH 6/6] docs: archis: add a per-architecture features list

2020-11-30 Thread Mauro Carvalho Chehab
Add a feature list matrix for each architecture to their
respective Kernel books.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/arm/features.rst  |  3 +++
 Documentation/arm/index.rst |  2 ++
 Documentation/arm64/features.rst|  3 +++
 Documentation/arm64/index.rst   |  2 ++
 Documentation/ia64/features.rst |  3 +++
 Documentation/ia64/index.rst|  2 ++
 Documentation/index.rst |  2 +-
 Documentation/m68k/features.rst |  3 +++
 Documentation/m68k/index.rst|  2 ++
 Documentation/mips/features.rst |  3 +++
 Documentation/mips/index.rst|  2 ++
 Documentation/nios2/index.rst   | 12 
 Documentation/openrisc/features.rst |  3 +++
 Documentation/openrisc/index.rst|  2 ++
 Documentation/parisc/features.rst   |  3 +++
 Documentation/parisc/index.rst  |  2 ++
 Documentation/powerpc/features.rst  |  3 +++
 Documentation/powerpc/index.rst |  2 ++
 Documentation/riscv/features.rst|  3 +++
 Documentation/riscv/index.rst   |  2 ++
 Documentation/s390/features.rst |  3 +++
 Documentation/s390/index.rst|  2 ++
 Documentation/sh/features.rst   |  3 +++
 Documentation/sh/index.rst  |  2 ++
 Documentation/sparc/features.rst|  3 +++
 Documentation/sparc/index.rst   |  2 ++
 Documentation/x86/features.rst  |  3 +++
 Documentation/x86/index.rst |  1 +
 Documentation/xtensa/features.rst   |  3 +++
 Documentation/xtensa/index.rst  |  2 ++
 30 files changed, 82 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/arm/features.rst
 create mode 100644 Documentation/arm64/features.rst
 create mode 100644 Documentation/ia64/features.rst
 create mode 100644 Documentation/m68k/features.rst
 create mode 100644 Documentation/mips/features.rst
 create mode 100644 Documentation/nios2/index.rst
 create mode 100644 Documentation/openrisc/features.rst
 create mode 100644 Documentation/parisc/features.rst
 create mode 100644 Documentation/powerpc/features.rst
 create mode 100644 Documentation/riscv/features.rst
 create mode 100644 Documentation/s390/features.rst
 create mode 100644 Documentation/sh/features.rst
 create mode 100644 Documentation/sparc/features.rst
 create mode 100644 Documentation/x86/features.rst
 create mode 100644 Documentation/xtensa/features.rst

diff --git a/Documentation/arm/features.rst b/Documentation/arm/features.rst
new file mode 100644
index ..7414ec03dd15
--- /dev/null
+++ b/Documentation/arm/features.rst
@@ -0,0 +1,3 @@
+.. SPDX-License-Identifier: GPL-2.0
+
+.. kernel-feat:: $srctree/Documentation/features arm
diff --git a/Documentation/arm/index.rst b/Documentation/arm/index.rst
index 5fc072dd0c5e..a2e9e1bba7b9 100644
--- a/Documentation/arm/index.rst
+++ b/Documentation/arm/index.rst
@@ -23,6 +23,8 @@ ARM Architecture
vlocks
porting
 
+   features
+
 SoC-specific documents
 ==
 
diff --git a/Documentation/arm64/features.rst b/Documentation/arm64/features.rst
new file mode 100644
index ..dfa4cb3cd3ef
--- /dev/null
+++ b/Documentation/arm64/features.rst
@@ -0,0 +1,3 @@
+.. SPDX-License-Identifier: GPL-2.0
+
+.. kernel-feat:: $srctree/Documentation/features arm64
diff --git a/Documentation/arm64/index.rst b/Documentation/arm64/index.rst
index 937634c49979..97d65ba12a35 100644
--- a/Documentation/arm64/index.rst
+++ b/Documentation/arm64/index.rst
@@ -24,6 +24,8 @@ ARM64 Architecture
 tagged-address-abi
 tagged-pointers
 
+features
+
 .. only::  subproject and html
 
Indices
diff --git a/Documentation/ia64/features.rst b/Documentation/ia64/features.rst
new file mode 100644
index ..d7226fdcf5f8
--- /dev/null
+++ b/Documentation/ia64/features.rst
@@ -0,0 +1,3 @@
+.. SPDX-License-Identifier: GPL-2.0
+
+.. kernel-feat:: $srctree/Documentation/features ia64
diff --git a/Documentation/ia64/index.rst b/Documentation/ia64/index.rst
index 4bdfe28067ee..761f2154dfa2 100644
--- a/Documentation/ia64/index.rst
+++ b/Documentation/ia64/index.rst
@@ -15,3 +15,5 @@ IA-64 Architecture
irq-redir
mca
serial
+
+   features
diff --git a/Documentation/index.rst b/Documentation/index.rst
index 57719744774c..5888e8a7272f 100644
--- a/Documentation/index.rst
+++ b/Documentation/index.rst
@@ -160,7 +160,7 @@ implementation.
ia64/index
m68k/index
mips/index
-   nios2/nios2
+   nios2/index
openrisc/index
parisc/index
powerpc/index
diff --git a/Documentation/m68k/features.rst b/Documentation/m68k/features.rst
new file mode 100644
index ..5107a2119472
--- /dev/null
+++ b/Documentation/m68k/features.rst
@@ -0,0 +1,3 @@
+.. SPDX-License-Identifier: GPL-2.0
+
+.. kernel-feat:: $srctree/Documentation/features m68k
diff --git a/Documentation/m68k/index.rst b/Documentation/m68k/index.rst
index b89cb6a86d9b..0f890dbb5fe2 100644
--- a/Documentation/m68k/index.rst
+++ b/Documentation/m68k/index.rst
@@ -10,6 +10,8 @@ m68k Architecture
kernel-options

[PATCH 0/6] Add documentation for Documentation/features at the built docs

2020-11-30 Thread Mauro Carvalho Chehab
s of all
files under Documentation/features (currently, 45 files) at the
Kernel documentation, which is, IMO, a good thing to do.

Regards,
Mauro

Mauro Carvalho Chehab (6):
  scripts: get_feat.pl: add a script to handle Documentation/features
  scripts: get_feat.pl: improve matrix output
  scripts: get_feat.pl: use its implementation for list-arch.sh
  sphinx: kernel_feat.py: add a script to parse feature files
  docs: admin-guide: add a features list
  docs: archis: add a per-architecture features list

 Documentation/admin-guide/features.rst |   3 +
 Documentation/admin-guide/index.rst|   1 +
 Documentation/arm/features.rst |   3 +
 Documentation/arm/index.rst|   2 +
 Documentation/arm64/features.rst   |   3 +
 Documentation/arm64/index.rst  |   2 +
 Documentation/conf.py  |   2 +-
 Documentation/features/list-arch.sh|  17 +-
 Documentation/ia64/features.rst|   3 +
 Documentation/ia64/index.rst   |   2 +
 Documentation/index.rst|   2 +-
 Documentation/m68k/features.rst|   3 +
 Documentation/m68k/index.rst   |   2 +
 Documentation/mips/features.rst|   3 +
 Documentation/mips/index.rst   |   2 +
 Documentation/nios2/index.rst  |  12 +
 Documentation/openrisc/features.rst|   3 +
 Documentation/openrisc/index.rst   |   2 +
 Documentation/parisc/features.rst  |   3 +
 Documentation/parisc/index.rst |   2 +
 Documentation/powerpc/features.rst |   3 +
 Documentation/powerpc/index.rst|   2 +
 Documentation/riscv/features.rst   |   3 +
 Documentation/riscv/index.rst  |   2 +
 Documentation/s390/features.rst|   3 +
 Documentation/s390/index.rst   |   2 +
 Documentation/sh/features.rst  |   3 +
 Documentation/sh/index.rst |   2 +
 Documentation/sparc/features.rst   |   3 +
 Documentation/sparc/index.rst  |   2 +
 Documentation/sphinx/kernel_feat.py| 169 
 Documentation/x86/features.rst |   3 +
 Documentation/x86/index.rst|   1 +
 Documentation/xtensa/features.rst  |   3 +
 Documentation/xtensa/index.rst |   2 +
 scripts/get_feat.pl| 552 +
 36 files changed, 810 insertions(+), 17 deletions(-)
 create mode 100644 Documentation/admin-guide/features.rst
 create mode 100644 Documentation/arm/features.rst
 create mode 100644 Documentation/arm64/features.rst
 create mode 100644 Documentation/ia64/features.rst
 create mode 100644 Documentation/m68k/features.rst
 create mode 100644 Documentation/mips/features.rst
 create mode 100644 Documentation/nios2/index.rst
 create mode 100644 Documentation/openrisc/features.rst
 create mode 100644 Documentation/parisc/features.rst
 create mode 100644 Documentation/powerpc/features.rst
 create mode 100644 Documentation/riscv/features.rst
 create mode 100644 Documentation/s390/features.rst
 create mode 100644 Documentation/sh/features.rst
 create mode 100644 Documentation/sparc/features.rst
 create mode 100644 Documentation/sphinx/kernel_feat.py
 create mode 100644 Documentation/x86/features.rst
 create mode 100644 Documentation/xtensa/features.rst
 create mode 100755 scripts/get_feat.pl

-- 
2.28.0




Duplicated ABI entries - Was: Re: [PATCH v2 20/39] docs: ABI: testing: make the files compatible with ReST output

2020-11-09 Thread Mauro Carvalho Chehab
Hi Jonathan,

Em Sun, 8 Nov 2020 16:56:21 +
Jonathan Cameron  escreveu:

> > PS.: the IIO subsystem is the one that currently has more duplicated
> > ABI entries:  
> > $ ./scripts/get_abi.pl validate 2>&1|grep iio
> > Warning: /sys/bus/iio/devices/iio:deviceX/in_accel_x_calibbias is defined 2 
> > times:  Documentation/ABI/testing/sysfs-bus-iio-icm42600:0  
> > Documentation/ABI/testing/sysfs-bus-iio:394
> > Warning: /sys/bus/iio/devices/iio:deviceX/in_accel_y_calibbias is defined 2 
> > times:  Documentation/ABI/testing/sysfs-bus-iio-icm42600:1  
> > Documentation/ABI/testing/sysfs-bus-iio:395
> > Warning: /sys/bus/iio/devices/iio:deviceX/in_accel_z_calibbias is defined 2 
> > times:  Documentation/ABI/testing/sysfs-bus-iio-icm42600:2  
> > Documentation/ABI/testing/sysfs-bus-iio:396
> > Warning: /sys/bus/iio/devices/iio:deviceX/in_anglvel_x_calibbias is defined 
> > 2 times:  Documentation/ABI/testing/sysfs-bus-iio-icm42600:3  
> > Documentation/ABI/testing/sysfs-bus-iio:397
> > Warning: /sys/bus/iio/devices/iio:deviceX/in_anglvel_y_calibbias is defined 
> > 2 times:  Documentation/ABI/testing/sysfs-bus-iio-icm42600:4  
> > Documentation/ABI/testing/sysfs-bus-iio:398
> > Warning: /sys/bus/iio/devices/iio:deviceX/in_anglvel_z_calibbias is defined 
> > 2 times:  Documentation/ABI/testing/sysfs-bus-iio-icm42600:5  
> > Documentation/ABI/testing/sysfs-bus-iio:399
> > Warning: /sys/bus/iio/devices/iio:deviceX/in_count0_preset is defined 2 
> > times:  Documentation/ABI/testing/sysfs-bus-iio-timer-stm32:100  
> > Documentation/ABI/testing/sysfs-bus-iio-lptimer-stm32:0
> > Warning: /sys/bus/iio/devices/iio:deviceX/in_count0_quadrature_mode is 
> > defined 2 times:  Documentation/ABI/testing/sysfs-bus-iio-timer-stm32:117  
> > Documentation/ABI/testing/sysfs-bus-iio-lptimer-stm32:14
> > Warning: 
> > /sys/bus/iio/devices/iio:deviceX/in_count_quadrature_mode_available is 
> > defined 3 times:  
> > Documentation/ABI/testing/sysfs-bus-iio-counter-104-quad-8:2  
> > Documentation/ABI/testing/sysfs-bus-iio-timer-stm32:111  
> > Documentation/ABI/testing/sysfs-bus-iio-lptimer-stm32:8
> > Warning: /sys/bus/iio/devices/iio:deviceX/out_altvoltageY_frequency is 
> > defined 2 times:  
> > Documentation/ABI/testing/sysfs-bus-iio-frequency-adf4371:0  
> > Documentation/ABI/testing/sysfs-bus-iio:599
> > Warning: /sys/bus/iio/devices/iio:deviceX/out_altvoltageY_powerdown is 
> > defined 2 times:  
> > Documentation/ABI/testing/sysfs-bus-iio-frequency-adf4371:36  
> > Documentation/ABI/testing/sysfs-bus-iio:588
> > Warning: /sys/bus/iio/devices/iio:deviceX/out_currentY_raw is defined 2 
> > times:  Documentation/ABI/testing/sysfs-bus-iio-light-lm3533-als:43  
> > Documentation/ABI/testing/sysfs-bus-iio-health-afe440x:38
> > Warning: /sys/bus/iio/devices/iio:deviceX/out_current_heater_raw is defined 
> > 2 times:  Documentation/ABI/testing/sysfs-bus-iio-humidity-hdc2010:0  
> > Documentation/ABI/testing/sysfs-bus-iio-humidity-hdc100x:0
> > Warning: /sys/bus/iio/devices/iio:deviceX/out_current_heater_raw_available 
> > is defined 2 times:  
> > Documentation/ABI/testing/sysfs-bus-iio-humidity-hdc2010:1  
> > Documentation/ABI/testing/sysfs-bus-iio-humidity-hdc100x:1
> > Warning: /sys/bus/iio/devices/iio:deviceX/sensor_sensitivity is defined 2 
> > times:  Documentation/ABI/testing/sysfs-bus-iio-distance-srf08:0  
> > Documentation/ABI/testing/sysfs-bus-iio-proximity-as3935:8
> > Warning: /sys/bus/iio/devices/triggerX/sampling_frequency is defined 2 
> > times:  Documentation/ABI/testing/sysfs-bus-iio-timer-stm32:92  
> > Documentation/ABI/testing/sysfs-bus-iio:45  

> 
> That was intentional.  Often these provide more information on the
> ABI for a particular device than is present in the base ABI doc.

FYI, right now, there are 20 duplicated entries, being 16 of them
from IIO, on those files:

$ ./scripts/get_abi.pl validate 2>&1|perl -ne 'if 
(m,(Documentation/\S+)\:,g) { print "$1\n" }'|sort|uniq
Documentation/ABI/stable/sysfs-driver-w1_ds28e04
Documentation/ABI/testing/sysfs-bus-iio-counter-104-quad-8
Documentation/ABI/testing/sysfs-bus-iio-distance-srf08
Documentation/ABI/testing/sysfs-bus-iio-frequency-adf4371
Documentation/ABI/testing/sysfs-bus-iio-humidity-hdc2010
Documentation/ABI/testing/sysfs-bus-iio-icm42600
Documentation/ABI/testing/sysfs-bus-iio-light-lm3533-als
Documentation/ABI/testing/sysfs-bus-iio-timer-stm32
Documentation/ABI/testing/sysfs-class-backlight-adp8860
Documentation/ABI/testing/sysfs-class-led-trigger-pattern
Documentation/ABI/testing/sysfs-kernel-iommu_groups

> 
> A bit like when we have additional description for dt binding properties
> for a particular device, even though they are standard properties.
> 
> Often a standard property allows for more values than the specific
> one for a particular device.  There can also be obscuring coupling
> between sysfs attributes due to hardware restrictions 

Re: [PATCH v2 20/39] docs: ABI: testing: make the files compatible with ReST output

2020-11-02 Thread Mauro Carvalho Chehab
Em Mon, 2 Nov 2020 13:46:41 +0100
Greg Kroah-Hartman  escreveu:

> On Mon, Nov 02, 2020 at 12:04:36PM +0100, Fabrice Gasnier wrote:
> > On 10/30/20 11:09 AM, Mauro Carvalho Chehab wrote:  
> > > Em Fri, 30 Oct 2020 10:19:12 +0100
> > > Fabrice Gasnier  escreveu:
> > >   
> > >> Hi Mauro,
> > >>
> > >> [...]
> > >>  
> > >>>  
> > >>> +What:  
> > >>> /sys/bus/iio/devices/iio:deviceX/in_count_quadrature_mode_available
> > >>> +KernelVersion: 4.12
> > >>> +Contact:   benjamin.gaign...@st.com
> > >>> +Description:
> > >>> +   Reading returns the list possible quadrature modes.
> > >>> +
> > >>> +What:  
> > >>> /sys/bus/iio/devices/iio:deviceX/in_count0_quadrature_mode
> > >>> +KernelVersion: 4.12
> > >>> +Contact:   benjamin.gaign...@st.com
> > >>> +Description:
> > >>> +   Configure the device counter quadrature modes:
> > >>> +
> > >>> +   channel_A:
> > >>> +   Encoder A input servers as the count input and 
> > >>> B as
> > >>> +   the UP/DOWN direction control input.
> > >>> +
> > >>> +   channel_B:
> > >>> +   Encoder B input serves as the count input and A 
> > >>> as
> > >>> +   the UP/DOWN direction control input.
> > >>> +
> > >>> +   quadrature:
> > >>> +   Encoder A and B inputs are mixed to get 
> > >>> direction
> > >>> +   and count with a scale of 0.25.
> > >>> +
> > >>  
> > > 
> > > Hi Fabrice,
> > >   
> > >> I just noticed that since Jonathan question in v1.
> > >>
> > >> Above ABI has been moved in the past as discussed in [1]. You can take a
> > >> look at:
> > >> b299d00 IIO: stm32: Remove quadrature related functions from trigger 
> > >> driver
> > >>
> > >> Could you please remove the above chunk ?
> > >>
> > >> With that, for the stm32 part:
> > >> Acked-by: Fabrice Gasnier   
> > > 
> > > 
> > > Hmm... probably those were re-introduced due to a rebase. This
> > > series were originally written about 1,5 years ago.
> > > 
> > > I'll drop those hunks.  
> > 
> > Hi Mauro, Greg,
> > 
> > I just figured out this patch has been applied with above hunk.
> > 
> > This should be dropped: is there a fix on its way already ?
> > (I may have missed it)  
> 
> Can you send a fix for just this hunk?

Hmm...

$ git grep 
/sys/bus/iio/devices/iio:deviceX/in_count_quadrature_mode_available
Documentation/ABI/testing/sysfs-bus-iio-counter-104-quad-8:What:
/sys/bus/iio/devices/iio:deviceX/in_count_quadrature_mode_available
Documentation/ABI/testing/sysfs-bus-iio-lptimer-stm32:What: 
/sys/bus/iio/devices/iio:deviceX/in_count_quadrature_mode_available
Documentation/ABI/testing/sysfs-bus-iio-timer-stm32:What:   
/sys/bus/iio/devices/iio:deviceX/in_count_quadrature_mode_available

Even re-doing the changes from 
changeset b299d00420e2 ("IIO: stm32: Remove quadrature related functions from 
trigger driver")
at Documentation/ABI/testing/sysfs-bus-iio-timer-stm32, there's still
a third duplicate of some of those, as reported by the script:

$ ./scripts/get_abi.pl validate 2>&1|grep quadra
Warning: /sys/bus/iio/devices/iio:deviceX/in_count0_quadrature_mode is 
defined 2 times:  Documentation/ABI/testing/sysfs-bus-iio-timer-stm32:117  
Documentation/ABI/testing/sysfs-bus-iio-lptimer-stm32:14
Warning: 
/sys/bus/iio/devices/iio:deviceX/in_count_quadrature_mode_available is defined 
3 times:  Documentation/ABI/testing/sysfs-bus-iio-counter-104-quad-8:2  
Documentation/ABI/testing/sysfs-bus-iio-timer-stm32:111  
Documentation/ABI/testing/sysfs-bus-iio-lptimer-stm32:8

As in_count_quadrature_mode_available is also defined at:
Documentation/ABI/testing/sysfs-bus-iio-counter-104-quad-8:2

The best here seems to have a patch that will also drop the other
duplication of this, probably moving in_count_quadrature_mode_available
to a generic node probably placing it inside 
Documentation/ABI/testing/sysfs-bus-iio.

Comments?

Thanks,
Mauro

PS.: the IIO subsystem is the one that currently has more duplic

Re: [PATCH v2 20/39] docs: ABI: testing: make the files compatible with ReST output

2020-10-30 Thread Mauro Carvalho Chehab
Em Fri, 30 Oct 2020 10:19:12 +0100
Fabrice Gasnier  escreveu:

> Hi Mauro,
> 
> [...]
> 
> >  
> > +What:  
> > /sys/bus/iio/devices/iio:deviceX/in_count_quadrature_mode_available
> > +KernelVersion: 4.12
> > +Contact:   benjamin.gaign...@st.com
> > +Description:
> > +   Reading returns the list possible quadrature modes.
> > +
> > +What:  
> > /sys/bus/iio/devices/iio:deviceX/in_count0_quadrature_mode
> > +KernelVersion: 4.12
> > +Contact:   benjamin.gaign...@st.com
> > +Description:
> > +   Configure the device counter quadrature modes:
> > +
> > +   channel_A:
> > +   Encoder A input servers as the count input and B as
> > +   the UP/DOWN direction control input.
> > +
> > +   channel_B:
> > +   Encoder B input serves as the count input and A as
> > +   the UP/DOWN direction control input.
> > +
> > +   quadrature:
> > +   Encoder A and B inputs are mixed to get direction
> > +   and count with a scale of 0.25.
> > +  
> 

Hi Fabrice,

> I just noticed that since Jonathan question in v1.
> 
> Above ABI has been moved in the past as discussed in [1]. You can take a
> look at:
> b299d00 IIO: stm32: Remove quadrature related functions from trigger driver
> 
> Could you please remove the above chunk ?
> 
> With that, for the stm32 part:
> Acked-by: Fabrice Gasnier 


Hmm... probably those were re-introduced due to a rebase. This
series were originally written about 1,5 years ago.

I'll drop those hunks.

Thanks!
Mauro


[PATCH v2 19/39] docs: ABI: stable: make files ReST compatible

2020-10-30 Thread Mauro Carvalho Chehab
Several entries at the stable ABI files won't parse if we pass
them directly to the ReST output.

Adjust them, in order to allow adding their contents as-is at
the stable ABI book.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/ABI/stable/firewire-cdev|  4 +
 Documentation/ABI/stable/sysfs-acpi-pmprofile | 22 +++--
 Documentation/ABI/stable/sysfs-bus-firewire   |  3 +
 Documentation/ABI/stable/sysfs-bus-nvmem  | 19 ++--
 Documentation/ABI/stable/sysfs-bus-usb|  6 +-
 .../ABI/stable/sysfs-class-backlight  |  1 +
 .../ABI/stable/sysfs-class-infiniband | 93 +--
 Documentation/ABI/stable/sysfs-class-rfkill   | 13 ++-
 Documentation/ABI/stable/sysfs-class-tpm  | 90 +-
 Documentation/ABI/stable/sysfs-devices|  5 +-
 Documentation/ABI/stable/sysfs-driver-ib_srp  |  1 +
 .../ABI/stable/sysfs-firmware-efi-vars|  4 +
 .../ABI/stable/sysfs-firmware-opal-dump   |  5 +
 .../ABI/stable/sysfs-firmware-opal-elog   |  2 +
 Documentation/ABI/stable/sysfs-hypervisor-xen |  3 +
 Documentation/ABI/stable/vdso |  5 +-
 16 files changed, 176 insertions(+), 100 deletions(-)

diff --git a/Documentation/ABI/stable/firewire-cdev 
b/Documentation/ABI/stable/firewire-cdev
index f72ed653878a..c9e8ff026154 100644
--- a/Documentation/ABI/stable/firewire-cdev
+++ b/Documentation/ABI/stable/firewire-cdev
@@ -14,12 +14,14 @@ Description:
Each /dev/fw* is associated with one IEEE 1394 node, which can
be remote or local nodes.  Operations on a /dev/fw* file have
different scope:
+
  - The 1394 node which is associated with the file:
  - Asynchronous request transmission
  - Get the Configuration ROM
  - Query node ID
  - Query maximum speed of the path between this node
and local node
+
  - The 1394 bus (i.e. "card") to which the node is attached to:
  - Isochronous stream transmission and reception
  - Asynchronous stream transmission and reception
@@ -31,6 +33,7 @@ Description:
manager
  - Query cycle time
  - Bus reset initiation, bus reset event reception
+
  - All 1394 buses:
  - Allocation of IEEE 1212 address ranges on the local
link layers, reception of inbound requests to such
@@ -43,6 +46,7 @@ Description:
userland implement different access permission models, some
operations are restricted to /dev/fw* files that are associated
with a local node:
+
  - Addition of descriptors or directories to the local
nodes' Configuration ROM
  - PHY packet transmission and reception
diff --git a/Documentation/ABI/stable/sysfs-acpi-pmprofile 
b/Documentation/ABI/stable/sysfs-acpi-pmprofile
index 964c7a8afb26..fd97d22b677f 100644
--- a/Documentation/ABI/stable/sysfs-acpi-pmprofile
+++ b/Documentation/ABI/stable/sysfs-acpi-pmprofile
@@ -6,17 +6,21 @@ Description:  The ACPI pm_profile sysfs interface exports the 
platform
power management (and performance) requirement expectations
as provided by BIOS. The integer value is directly passed as
retrieved from the FADT ACPI table.
-Values: For possible values see ACPI specification:
+
+Values:For possible values see ACPI specification:
5.2.9 Fixed ACPI Description Table (FADT)
Field: Preferred_PM_Profile
 
Currently these values are defined by spec:
-   0 Unspecified
-   1 Desktop
-   2 Mobile
-   3 Workstation
-   4 Enterprise Server
-   5 SOHO Server
-   6 Appliance PC
-   7 Performance Server
+
+   == =
+   0  Unspecified
+   1  Desktop
+   2  Mobile
+   3  Workstation
+   4  Enterprise Server
+   5  SOHO Server
+   6  Appliance PC
+   7  Performance Server
>7 Reserved
+   == =
diff --git a/Documentation/ABI/stable/sysfs-bus-firewire 
b/Documentation/ABI/stable/sysfs-bus-firewire
index 41e5a0cd1e3e..9ac9eddb82ef 100644
--- a/Documentation/ABI/stable/sysfs-bus-firewire
+++ b/Documentation/ABI/stable/sysfs-bus-firewire
@@ -47,6 +47,7 @@ Description:
IEEE 1394 node device attribute.
Read-only and immutable.
 Values:1: The sysfs entry represents a local node (a 
controller card).
+
0: The sysfs entry represents 

Re: [PATCH 20/33] docs: ABI: testing: make the files compatible with ReST output

2020-10-30 Thread Mauro Carvalho Chehab
Em Thu, 29 Oct 2020 14:49:12 +
Jonathan Cameron  escreveu:

> On Wed, 28 Oct 2020 15:23:18 +0100
> Mauro Carvalho Chehab  wrote:
> 
> > From: Mauro Carvalho Chehab 
> > 
> > Some files over there won't parse well by Sphinx.
> > 
> > Fix them.
> > 
> > Signed-off-by: Mauro Carvalho Chehab 
> > Signed-off-by: Mauro Carvalho Chehab   
> 
> Query below...  I'm going to guess a rebase issue?

Yes. I sent this series about 1,5 years ago. On that time, it
ended by not being merged, as there were too much docs patches
floating around. 

The second SoB is not there on my tree. It was added by
git send-email ;-)

Anyway, fixed.

Thanks,
Mauro


Re: [PATCH 20/33] docs: ABI: testing: make the files compatible with ReST output

2020-10-29 Thread Mauro Carvalho Chehab
Hi Richard,

Em Wed, 28 Oct 2020 10:44:27 -0700
Richard Cochran  escreveu:

> On Wed, Oct 28, 2020 at 03:23:18PM +0100, Mauro Carvalho Chehab wrote:
> 
> > diff --git a/Documentation/ABI/testing/sysfs-uevent 
> > b/Documentation/ABI/testing/sysfs-uevent
> > index aa39f8d7bcdf..d0893dad3f38 100644
> > --- a/Documentation/ABI/testing/sysfs-uevent
> > +++ b/Documentation/ABI/testing/sysfs-uevent
> > @@ -19,7 +19,8 @@ Description:
> >  a transaction identifier so it's possible to use the same 
> > UUID
> >  value for one or more synthetic uevents in which case we
> >  logically group these uevents together for any userspace
> > -listeners. The UUID value appears in uevent as
> > +listeners. The UUID value appears in uevent as:  
> 
> I know almost nothing about Sphinx, but why have one colon here ^^^ and ...

Good point. After re-reading the text, this ":" doesn't belong here.

> 
> > +
> >  "SYNTH_UUID=----" 
> > environment
> >  variable.
> >  
> > @@ -30,18 +31,19 @@ Description:
> >  It's possible to define zero or more pairs - each pair is 
> > then
> >  delimited by a space character ' '. Each pair appears in
> >  synthetic uevent as "SYNTH_ARG_KEY=VALUE". That means the 
> > KEY
> > -name gains "SYNTH_ARG_" prefix to avoid possible collisions
> > +name gains `SYNTH_ARG_` prefix to avoid possible collisions
> >  with existing variables.
> >  
> > -Example of valid sequence written to the uevent file:
> > +Example of valid sequence written to the uevent file::  
> 
> ... two here?

The main issue that this patch wants to solve is here:

This generates synthetic uevent including these variables::

ACTION=add
SYNTH_ARG_A=1
SYNTH_ARG_B=abc
SYNTH_UUID=fe4d7c9d-b8c6-4a70-9ef1-3d8a58d18eed

On Sphinx, consecutive lines with the same indent belongs to the same
paragraph. So, without "::", the above will be displayed on a single line,
which is undesired.

using "::" tells Sphinx to display as-is. It will also place it into a a 
box (colored for html output) and using a monospaced font.

The change at the "uevent file:" line was done just for coherency
purposes.

Yet, after re-reading the text, there are other things that are not
coherent. So, I guess the enclosed patch will work better for sys-uevent.

Thanks,
Mauro

docs: ABI: sysfs-uevent: make it compatible with ReST output

- Replace " by ``, in order to use monospaced fonts;
- mark literal blocks as such.

Signed-off-by: Mauro Carvalho Chehab 

diff --git a/Documentation/ABI/testing/sysfs-uevent 
b/Documentation/ABI/testing/sysfs-uevent
index aa39f8d7bcdf..0b6227706b35 100644
--- a/Documentation/ABI/testing/sysfs-uevent
+++ b/Documentation/ABI/testing/sysfs-uevent
@@ -6,42 +6,46 @@ Description:
 Enable passing additional variables for synthetic uevents that
 are generated by writing /sys/.../uevent file.
 
-Recognized extended format is ACTION [UUID [KEY=VALUE ...].
+Recognized extended format is::
 
-The ACTION is compulsory - it is the name of the uevent action
-("add", "change", "remove"). There is no change compared to
-previous functionality here. The rest of the extended format
-is optional.
+   ACTION [UUID [KEY=VALUE ...]
+
+The ACTION is compulsory - it is the name of the uevent
+action (``add``, ``change``, ``remove``). There is no change
+compared to previous functionality here. The rest of the
+extended format is optional.
 
 You need to pass UUID first before any KEY=VALUE pairs.
-The UUID must be in "----"
+The UUID must be in ``----``
 format where 'x' is a hex digit. The UUID is considered to be
 a transaction identifier so it's possible to use the same UUID
 value for one or more synthetic uevents in which case we
 logically group these uevents together for any userspace
 listeners. The UUID value appears in uevent as
-"SYNTH_UUID=----" environment
+``SYNTH_UUID=----`` en

[PATCH 19/33] docs: ABI: stable: make files ReST compatible

2020-10-28 Thread Mauro Carvalho Chehab
From: Mauro Carvalho Chehab 

Several entries at the stable ABI files won't parse if we pass
them directly to the ReST output.

Adjust them, in order to allow adding their contents as-is at
the stable ABI book.

Signed-off-by: Mauro Carvalho Chehab 
Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/ABI/stable/firewire-cdev|  4 +
 Documentation/ABI/stable/sysfs-acpi-pmprofile | 22 +++--
 Documentation/ABI/stable/sysfs-bus-firewire   |  3 +
 Documentation/ABI/stable/sysfs-bus-nvmem  | 19 ++--
 Documentation/ABI/stable/sysfs-bus-usb|  6 +-
 .../ABI/stable/sysfs-class-backlight  |  1 +
 .../ABI/stable/sysfs-class-infiniband | 93 +--
 Documentation/ABI/stable/sysfs-class-rfkill   | 13 ++-
 Documentation/ABI/stable/sysfs-class-tpm  | 90 +-
 Documentation/ABI/stable/sysfs-devices|  5 +-
 Documentation/ABI/stable/sysfs-driver-ib_srp  |  1 +
 .../ABI/stable/sysfs-firmware-efi-vars|  4 +
 .../ABI/stable/sysfs-firmware-opal-dump   |  5 +
 .../ABI/stable/sysfs-firmware-opal-elog   |  2 +
 Documentation/ABI/stable/sysfs-hypervisor-xen |  3 +
 Documentation/ABI/stable/vdso |  5 +-
 16 files changed, 176 insertions(+), 100 deletions(-)

diff --git a/Documentation/ABI/stable/firewire-cdev 
b/Documentation/ABI/stable/firewire-cdev
index f72ed653878a..c9e8ff026154 100644
--- a/Documentation/ABI/stable/firewire-cdev
+++ b/Documentation/ABI/stable/firewire-cdev
@@ -14,12 +14,14 @@ Description:
Each /dev/fw* is associated with one IEEE 1394 node, which can
be remote or local nodes.  Operations on a /dev/fw* file have
different scope:
+
  - The 1394 node which is associated with the file:
  - Asynchronous request transmission
  - Get the Configuration ROM
  - Query node ID
  - Query maximum speed of the path between this node
and local node
+
  - The 1394 bus (i.e. "card") to which the node is attached to:
  - Isochronous stream transmission and reception
  - Asynchronous stream transmission and reception
@@ -31,6 +33,7 @@ Description:
manager
  - Query cycle time
  - Bus reset initiation, bus reset event reception
+
  - All 1394 buses:
  - Allocation of IEEE 1212 address ranges on the local
link layers, reception of inbound requests to such
@@ -43,6 +46,7 @@ Description:
userland implement different access permission models, some
operations are restricted to /dev/fw* files that are associated
with a local node:
+
  - Addition of descriptors or directories to the local
nodes' Configuration ROM
  - PHY packet transmission and reception
diff --git a/Documentation/ABI/stable/sysfs-acpi-pmprofile 
b/Documentation/ABI/stable/sysfs-acpi-pmprofile
index 964c7a8afb26..fd97d22b677f 100644
--- a/Documentation/ABI/stable/sysfs-acpi-pmprofile
+++ b/Documentation/ABI/stable/sysfs-acpi-pmprofile
@@ -6,17 +6,21 @@ Description:  The ACPI pm_profile sysfs interface exports the 
platform
power management (and performance) requirement expectations
as provided by BIOS. The integer value is directly passed as
retrieved from the FADT ACPI table.
-Values: For possible values see ACPI specification:
+
+Values:For possible values see ACPI specification:
5.2.9 Fixed ACPI Description Table (FADT)
Field: Preferred_PM_Profile
 
Currently these values are defined by spec:
-   0 Unspecified
-   1 Desktop
-   2 Mobile
-   3 Workstation
-   4 Enterprise Server
-   5 SOHO Server
-   6 Appliance PC
-   7 Performance Server
+
+   == =
+   0  Unspecified
+   1  Desktop
+   2  Mobile
+   3  Workstation
+   4  Enterprise Server
+   5  SOHO Server
+   6  Appliance PC
+   7  Performance Server
>7 Reserved
+   == =
diff --git a/Documentation/ABI/stable/sysfs-bus-firewire 
b/Documentation/ABI/stable/sysfs-bus-firewire
index 41e5a0cd1e3e..9ac9eddb82ef 100644
--- a/Documentation/ABI/stable/sysfs-bus-firewire
+++ b/Documentation/ABI/stable/sysfs-bus-firewire
@@ -47,6 +47,7 @@ Description:
IEEE 1394 node device attribute.
Read-only and immutable.
 Values:1: The sysfs entry represents a local node (a 
co

Re: [PATCH 2/2] dt: Remove booting-without-of.rst

2020-10-21 Thread Mauro Carvalho Chehab
Hi Rob,

Em Thu,  8 Oct 2020 09:24:20 -0500
Rob Herring  escreveu:

> booting-without-of.rstt is an ancient document that first outlined
> Flattened DeviceTree on PowerPC initially. The DT world has evolved a
> lot in the 15 years since and booting-without-of.rst is pretty stale.
> The name of the document itself is confusing if you don't understand the
> evolution from real 'OpenFirmware'. Most of what booting-without-of.rst
> contains is now in the DT specification (which evolved out of the
> ePAPR). The few things that weren't documented in the DT specification
> are now.
> 
> All that remains is the boot entry details, so let's move these to arch
> specific documents. The exception is arm which already has the same
> details documented.

Removing this document caused a warning at Documentation/arm/booting.rst:

$ ./scripts/documentation-file-ref-check 
Documentation/arm/booting.rst: 
Documentation/devicetree/booting-without-of.rst

as it mentions that the DTB format is described on booting-without-of.rst:

4b. Setup the device tree
-

The boot loader must load a device tree image (dtb) into system ram
at a 64bit aligned address and initialize it with the boot data.  The
dtb format is documented in 
Documentation/devicetree/booting-without-of.rst.
The kernel will look for the dtb magic value of 0xd00dfeed at the dtb
physical address to determine if a dtb has been passed instead of a
tagged list.

So, I guess that such part of the document needs to be moved to booting.rst.

Thanks,
Mauro


[PATCH v6 59/80] docs: powerpc: syscall64-abi.rst: fix a malformed table

2020-10-13 Thread Mauro Carvalho Chehab
As reported:

Documentation/powerpc/syscall64-abi.rst:53: WARNING: Malformed table.
Text in column margin in table line 2.

=== = 
--- For the sc instruction, differences with the ELF ABI ---
r0  Volatile  (System call number.)

This table requires a different notation to be valid.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/powerpc/syscall64-abi.rst | 32 -
 1 file changed, 16 insertions(+), 16 deletions(-)

diff --git a/Documentation/powerpc/syscall64-abi.rst 
b/Documentation/powerpc/syscall64-abi.rst
index 379817ca64d2..cf9b2857c72a 100644
--- a/Documentation/powerpc/syscall64-abi.rst
+++ b/Documentation/powerpc/syscall64-abi.rst
@@ -49,22 +49,22 @@ Register preservation rules
 Register preservation rules match the ELF ABI calling sequence with the
 following differences:
 
 For the sc instruction, differences with the ELF ABI ---
-=== = 
-r0  Volatile  (System call number.)
-r3  Volatile  (Parameter 1, and return value.)
-r4-r8   Volatile  (Parameters 2-6.)
-cr0 Volatile  (cr0.SO is the return error condition.)
-cr1, cr5-7  Nonvolatile
-lr  Nonvolatile
-=== = 
-
 For the scv 0 instruction, differences with the ELF ABI ---
-=== = 
-r0  Volatile  (System call number.)
-r3  Volatile  (Parameter 1, and return value.)
-r4-r8   Volatile  (Parameters 2-6.)
-=== = 
+++
+|For the sc instruction, differences with the ELF ABI   |
++--+--+--+
+| r0   | Volatile | (System call number.)   |
+| rr3  | Volatile | (Parameter 1, and return value.)|
+| rr4-r8   | Volatile | (Parameters 2-6.)   |
+| rcr0 | Volatile | (cr0.SO is the return error condition.)
 |
+| rcr1, cr5-7  | Nonvolatile  |
 |
+| rlr  | Nonvolatile  |
 |
++--+--+--+
+|  For the scv 0 instruction, differences with the ELF ABI  |
++--+--+--+
+| r0   | Volatile | (System call number.)   |
+| r3   | Volatile | (Parameter 1, and return value.)|
+| r4-r8| Volatile | (Parameters 2-6.)   |
++--+--+--+
 
 All floating point and vector data registers as well as control and status
 registers are nonvolatile.
-- 
2.26.2



Re: [trivial PATCH] treewide: Convert switch/case fallthrough; to break;

2020-09-10 Thread Mauro Carvalho Chehab
Em Wed, 09 Sep 2020 13:06:39 -0700
Joe Perches  escreveu:

> fallthrough to a separate case/default label break; isn't very readable.
> 
> Convert pseudo-keyword fallthrough; statements to a simple break; when
> the next label is case or default and the only statement in the next
> label block is break;
> 
> Found using:
> 
> $ grep-2.5.4 -rP --include=*.[ch] -n 
> "fallthrough;(\s*(case\s+\w+|default)\s*:\s*){1,7}break;" *
> 
> Miscellanea:
> 
> o Move or coalesce a couple label blocks above a default: block.
> 
> Signed-off-by: Joe Perches 
> ---
> 
> Compiled allyesconfig x86-64 only.
> A few files for other arches were not compiled.
> 


>  drivers/media/dvb-frontends/drxd_hard.c   |  2 +-
>  drivers/media/i2c/ov5640.c|  2 +-
>  drivers/media/i2c/ov6650.c|  5 ++---
>  drivers/media/i2c/smiapp/smiapp-core.c|  2 +-
>  drivers/media/i2c/tvp5150.c   |  2 +-
>  drivers/media/pci/ddbridge/ddbridge-core.c|  2 +-
>  drivers/media/usb/cpia2/cpia2_core.c  |  2 +-

For media drivers:

Reviewed-by: Mauro Carvalho Chehab 


Thanks,
Mauro


[PATCH v2 00/15] Documentation fixes

2020-06-23 Thread Mauro Carvalho Chehab
Hi Jon,

As requested, this is a rebase of a previous series posted on Jan, 15.

Since then, several patches got merged via other trees or became
obsolete. There were also 2 patches before that fits better at the
ReST conversion patchset. So, I'll be sending it on another patch
series together with the remaining ReST conversions.

I also added reviews/acks received.

So, the series reduced from 29 to 15 patches.

Let's hope b4 would be able to properly handle this one.

Regards,
Mauro

Mauro Carvalho Chehab (15):
  mm: vmalloc.c: remove a kernel-doc annotation from a removed parameter
  net: dev: add a missing kernel-doc annotation
  net: netdevice.h: add a description for napi_defer_hard_irqs
  scripts/kernel-doc: parse __ETHTOOL_DECLARE_LINK_MODE_MASK
  net: pylink.h: add kernel-doc descriptions for new fields at
phylink_config
  scripts/kernel-doc: handle function pointer prototypes
  fs: fs.h: fix a kernel-doc parameter description
  kcsan: fix a kernel-doc warning
  selftests/vm/keys: fix a broken reference at protection_keys.c
  docs: hugetlbpage.rst: fix some warnings
  docs: powerpc: fix some issues at vas-api.rst
  docs: driver-model: remove a duplicated markup at driver.rst
  docs: ABI: fix a typo when pointing to w1-generic.rst
  docs: fix references for DMA*.txt files
  docs: fs: proc.rst: convert a new chapter to ReST

 .../ABI/testing/sysfs-driver-w1_therm |  2 +-
 Documentation/PCI/pci.rst |  6 +--
 Documentation/admin-guide/mm/hugetlbpage.rst  | 23 +++---
 Documentation/block/biodoc.rst|  2 +-
 Documentation/bus-virt-phys-mapping.txt   |  2 +-
 Documentation/core-api/dma-api.rst|  6 +--
 Documentation/core-api/dma-isa-lpc.rst|  2 +-
 .../driver-api/driver-model/driver.rst|  2 -
 Documentation/driver-api/usb/dma.rst  |  6 +--
 Documentation/filesystems/proc.rst| 44 +--
 Documentation/powerpc/vas-api.rst | 23 +++---
 .../translations/ko_KR/memory-barriers.txt|  6 +--
 arch/ia64/hp/common/sba_iommu.c   | 12 ++---
 arch/parisc/kernel/pci-dma.c  |  2 +-
 arch/x86/include/asm/dma-mapping.h|  4 +-
 arch/x86/kernel/amd_gart_64.c |  2 +-
 drivers/parisc/sba_iommu.c| 14 +++---
 include/linux/dma-mapping.h   |  2 +-
 include/linux/fs.h|  2 +-
 include/linux/kcsan-checks.h  | 10 +++--
 include/linux/netdevice.h |  2 +
 include/linux/phylink.h   |  4 ++
 include/media/videobuf-dma-sg.h   |  2 +-
 kernel/dma/debug.c|  2 +-
 mm/vmalloc.c  |  1 -
 net/core/dev.c|  1 +
 scripts/kernel-doc|  7 +++
 tools/testing/selftests/vm/protection_keys.c  |  2 +-
 28 files changed, 114 insertions(+), 79 deletions(-)

-- 
2.26.2




[PATCH v2 11/15] docs: powerpc: fix some issues at vas-api.rst

2020-06-23 Thread Mauro Carvalho Chehab
There are a few issues on this document, when built via the
building with ``make htmldocs``:

Documentation/powerpc/vas-api.rst:116: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:116: WARNING: Inline emphasis 
start-string without end-string.
Documentation/powerpc/vas-api.rst:117: WARNING: Block quote ends without a 
blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:117: WARNING: Inline emphasis 
start-string without end-string.
Documentation/powerpc/vas-api.rst:120: WARNING: Definition list ends 
without a blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:124: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:133: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:135: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:150: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:151: WARNING: Block quote ends without a 
blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:161: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:176: WARNING: Definition list ends 
without a blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:253: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:253: WARNING: Inline emphasis 
start-string without end-string.
Documentation/powerpc/vas-api.rst:259: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:261: WARNING: Block quote ends without a 
blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:266: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:267: WARNING: Block quote ends without a 
blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:270: WARNING: Definition list ends 
without a blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:271: WARNING: Definition list ends 
without a blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:273: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:274: WARNING: Block quote ends without a 
blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:277: WARNING: Definition list ends 
without a blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:278: WARNING: Definition list ends 
without a blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:280: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:287: WARNING: Block quote ends without a 
blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:289: WARNING: Block quote ends without a 
blank line; unexpected unindent.

Fixes: c12e38b1d52e ("Documentation/powerpc: VAS API")
Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/powerpc/vas-api.rst | 23 ++-
 1 file changed, 18 insertions(+), 5 deletions(-)

diff --git a/Documentation/powerpc/vas-api.rst 
b/Documentation/powerpc/vas-api.rst
index 1217c2f1595e..b7fdbe560010 100644
--- a/Documentation/powerpc/vas-api.rst
+++ b/Documentation/powerpc/vas-api.rst
@@ -87,6 +87,7 @@ Applications may chose a specific instance of the NX 
co-processor using
 the vas_id field in the VAS_TX_WIN_OPEN ioctl as detailed below.
 
 A userspace library libnxz is available here but still in development:
+
 https://github.com/abalib/power-gzip
 
 Applications that use inflate / deflate calls can link with libnxz
@@ -110,6 +111,7 @@ Applications should use the VAS_TX_WIN_OPEN ioctl as 
follows to establish
 a connection with NX co-processor engine:
 
::
+
struct vas_tx_win_open_attr {
__u32   version;
__s16   vas_id; /* specific instance of vas or -1
@@ -119,8 +121,10 @@ a connection with NX co-processor engine:
__u64   reserved2[6];
};
 
-   version: The version field must be currently set to 1.
-   vas_id: If '-1' is passed, kernel will make a best-effort attempt
+   version:
+   The version field must be currently set to 1.
+   vas_id:
+   If '-1' is passed, kernel will make a best-effort attempt
to assign an optimal instance of NX for the process. To
select the specific VAS instance, refer
"Discovery of available VAS engines" section below.
@@ -129,7 +133,8 @@ a connection with NX co-processor engine:
and must be set to 0.
 
The attributes attr for the VAS_TX_WIN_OPEN ioctl are defined as
-   follows:
+   follows::
+
#define VAS_MAGIC 'v'
#define VAS_TX_WIN_OPEN _IOW(VAS_MAGIC, 1,
struct vas_tx_win_open_attr)
@@ -141,6 +146,8 @@ a connection with NX co-processor engine:
returns -1 and sets the errno variable to indicate the error.
 

[PATCH 00/29] Documentation fixes

2020-06-15 Thread Mauro Carvalho Chehab
Hi Jon,

That's a bunch of files I have to be applied on the top of v5.8-rc1 fixing
documentation warnings. I already removed some duplicated stuff.

Regards,
Mauro

Mauro Carvalho Chehab (29):
  mm: vmalloc.c: remove a kernel-doc annotation from a removed parameter
  net: dev: add a missing kernel-doc annotation
  net: netdevice.h: add a description for napi_defer_hard_irqs
  scripts/kernel-doc: parse __ETHTOOL_DECLARE_LINK_MODE_MASK
  net: pylink.h: add kernel-doc descriptions for new fields at
phylink_config
  scripts/kernel-doc: handle function pointer prototypes
  fs: fs.h: fix a kernel-doc parameter description
  gpio: driver.h: fix kernel-doc markup
  kcsan: fix a kernel-doc warning
  rcu: fix some kernel-doc warnings
  fs: docs: f2fs.rst: fix a broken table
  dt: update a reference for reneases pcar file renamed to yaml
  dt: fix broken links due to txt->yaml renames
  dt: Fix broken references to renamed docs
  dt: fix reference to olpc,xo1.75-ec.txt
  selftests/vm/keys: fix a broken reference at protection_keys.c
  docs: hugetlbpage.rst: fix some warnings
  docs: powerpc: fix some issues at vas-api.rst
  docs: driver-model: remove a duplicated markup at driver.rst
  docs: watch_queue.rst: supress some Sphinx warnings and move to
core-api
  docs: device-mapper: add dm-ebs.rst to an index file
  docs: it_IT: add two missing references
  docs: ABI: fix a typo when pointing to w1-generic.rst
  docs: fs: locking.rst: fix a broken table
  docs: add bus-virt-phys-mapping.txt to core-api
  docs: fix references for DMA*.txt files
  docs: dt: minor adjustments at writing-schema.rst
  docs: fs: proc.rst: fix a warning due to a merge conflict
  docs: fs: proc.rst: convert a new chapter to ReST

 .../ABI/testing/sysfs-driver-w1_therm |   2 +-
 Documentation/PCI/pci.rst |   6 +-
 .../admin-guide/device-mapper/index.rst   |   1 +
 Documentation/admin-guide/mm/hugetlbpage.rst  |  25 ++-
 Documentation/block/biodoc.rst|   2 +-
 .../bus-virt-phys-mapping.rst}|   2 +-
 Documentation/core-api/dma-api.rst|   6 +-
 Documentation/core-api/dma-isa-lpc.rst|   2 +-
 Documentation/core-api/index.rst  |   2 +
 Documentation/{ => core-api}/watch_queue.rst  |  34 ++--
 .../bindings/arm/freescale/fsl,scu.txt|   2 +-
 .../bindings/display/bridge/sii902x.txt   |   2 +-
 .../bindings/display/imx/fsl-imx-drm.txt  |   4 +-
 .../devicetree/bindings/display/imx/ldb.txt   |   4 +-
 .../display/rockchip/rockchip-drm.yaml|   2 +-
 .../bindings/misc/olpc,xo1.75-ec.txt  |   2 +-
 .../bindings/net/mediatek-bluetooth.txt   |   2 +-
 .../bindings/pinctrl/renesas,pfc-pinctrl.txt  |   2 +-
 .../bindings/sound/audio-graph-card.txt   |   2 +-
 .../bindings/sound/st,sti-asoc-card.txt   |   2 +-
 .../bindings/spi/qcom,spi-geni-qcom.txt   |   2 +-
 Documentation/devicetree/writing-schema.rst   |   9 +-
 .../driver-api/driver-model/driver.rst|   2 -
 Documentation/driver-api/usb/dma.rst  |   6 +-
 Documentation/filesystems/f2fs.rst| 150 --
 Documentation/filesystems/locking.rst |   6 +-
 Documentation/filesystems/proc.rst|  46 +++---
 Documentation/memory-barriers.txt |   6 +-
 Documentation/mips/ingenic-tcu.rst|   2 +-
 Documentation/powerpc/vas-api.rst |  23 ++-
 Documentation/security/keys/core.rst  |   2 +-
 .../it_IT/process/management-style.rst|   2 +
 .../it_IT/process/submitting-patches.rst  |   2 +
 .../translations/ko_KR/memory-barriers.txt|   6 +-
 MAINTAINERS   |   8 +-
 arch/ia64/hp/common/sba_iommu.c   |  12 +-
 arch/parisc/kernel/pci-dma.c  |   2 +-
 arch/x86/include/asm/dma-mapping.h|   4 +-
 arch/x86/kernel/amd_gart_64.c |   2 +-
 drivers/parisc/sba_iommu.c|  14 +-
 include/linux/dma-mapping.h   |   2 +-
 include/linux/fs.h|   2 +-
 include/linux/gpio/driver.h   |   2 +-
 include/linux/kcsan-checks.h  |  10 +-
 include/linux/netdevice.h |   2 +
 include/linux/phylink.h   |   4 +
 include/linux/rculist.h   |   2 +-
 include/linux/watch_queue.h   |   2 +-
 include/media/videobuf-dma-sg.h   |   2 +-
 init/Kconfig  |   2 +-
 kernel/dma/debug.c|   2 +-
 kernel/watch_queue.c  |   2 +-
 mm/vmalloc.c  |   1 -
 net/core/dev.c|   1 +
 scripts/kernel-doc|   7 +
 tools/testing/selftests/vm/protection_keys.c  |   2 +-
 56 files changed, 282 insertions(+), 175 deletions(-)
 rename Documentation/{bus-virt-phys-mapping.txt => 

[PATCH 15/22] docs: powerpc: convert vcpudispatch_stats.txt to ReST

2020-06-15 Thread Mauro Carvalho Chehab
- Add a SPDX header;
- Use standard markup for document title;
- Adjust identation on lists and add blank lines where
  needed;
- Add it to the powerpc index.rst file.

Acked-by: Michael Ellerman  # powerpc
Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/powerpc/index.rst |  1 +
 ...ispatch_stats.txt => vcpudispatch_stats.rst} | 17 -
 2 files changed, 13 insertions(+), 5 deletions(-)
 rename Documentation/powerpc/{vcpudispatch_stats.txt => 
vcpudispatch_stats.rst} (94%)

diff --git a/Documentation/powerpc/index.rst b/Documentation/powerpc/index.rst
index afe2d5e54db6..748bf483b1c2 100644
--- a/Documentation/powerpc/index.rst
+++ b/Documentation/powerpc/index.rst
@@ -31,6 +31,7 @@ powerpc
 transactional_memory
 ultravisor
 vas-api
+vcpudispatch_stats
 
 .. only::  subproject and html
 
diff --git a/Documentation/powerpc/vcpudispatch_stats.txt 
b/Documentation/powerpc/vcpudispatch_stats.rst
similarity index 94%
rename from Documentation/powerpc/vcpudispatch_stats.txt
rename to Documentation/powerpc/vcpudispatch_stats.rst
index e21476bfd78c..5704657a5987 100644
--- a/Documentation/powerpc/vcpudispatch_stats.txt
+++ b/Documentation/powerpc/vcpudispatch_stats.rst
@@ -1,5 +1,8 @@
-VCPU Dispatch Statistics:
-=
+.. SPDX-License-Identifier: GPL-2.0
+
+
+VCPU Dispatch Statistics
+
 
 For Shared Processor LPARs, the POWER Hypervisor maintains a relatively
 static mapping of the LPAR processors (vcpus) to physical processor
@@ -20,25 +23,29 @@ The statistics themselves are available by reading the 
procfs file
 a vcpu as represented by the first field, followed by 8 numbers.
 
 The first number corresponds to:
+
 1. total vcpu dispatches since the beginning of statistics collection
 
 The next 4 numbers represent vcpu dispatch dispersions:
+
 2. number of times this vcpu was dispatched on the same processor as last
time
 3. number of times this vcpu was dispatched on a different processor core
as last time, but within the same chip
 4. number of times this vcpu was dispatched on a different chip
 5. number of times this vcpu was dispatches on a different socket/drawer
-(next numa boundary)
+   (next numa boundary)
 
 The final 3 numbers represent statistics in relation to the home node of
 the vcpu:
+
 6. number of times this vcpu was dispatched in its home node (chip)
 7. number of times this vcpu was dispatched in a different node
 8. number of times this vcpu was dispatched in a node further away (numa
-distance)
+   distance)
+
+An example output::
 
-An example output:
 $ sudo cat /proc/powerpc/vcpudispatch_stats
 cpu0 6839 4126 2683 30 0 6821 18 0
 cpu1 2515 1274 1229 12 0 2509 6 0
-- 
2.26.2



[PATCH 00/22] ReST conversion patches (final?)

2020-06-15 Thread Mauro Carvalho Chehab
Hi Jon,

That's my final(*) series of conversion patches from .txt to ReST.

(*) Well, running the script I'm using to check, I noticed a couple of new 
*.txt files.
If I have some time, I'll try to address those last pending things for v5.9.

Mauro Carvalho Chehab (22):
  docs: dt: convert booting-without-of.txt to ReST format
  docs: thermal: convert cpu-idle-cooling.rst to ReST
  docs: crypto: convert asymmetric-keys.txt to ReST
  docs: crypto: convert api-intro.txt to ReST format
  docs: crypto: convert async-tx-api.txt to ReST format
  docs: crypto: descore-readme.txt: convert to ReST format
  docs: misc-devices/spear-pcie-gadget.txt: convert to ReST
  docs: misc-devices/pci-endpoint-test.txt: convert to ReST
  docs: misc-devices/pci-endpoint-test.txt: convert to ReST
  docs: misc-devices/c2port.txt: convert to ReST format
  docs: misc-devices/bh1770glc.txt: convert to ReST
  docs: misc-devices/apds990x.txt: convert to ReST format
  docs: pci: endpoint/function/binding/pci-test.txt convert to ReST
  docs: arm64: convert perf.txt to ReST format
  docs: powerpc: convert vcpudispatch_stats.txt to ReST
  docs: sh: convert new-machine.txt to ReST
  docs: sh: convert register-banks.txt to ReST
  docs: trace: ring-buffer-design.txt: convert to ReST format
  docs: move other kAPI documents to core-api
  docs: move remaining stuff under Documentation/*.txt to
Documentation/staging
  docs: staging: don't use literalinclude
  docs: staging: use small font for literal includes

 .../endpoint/function/binding/pci-test.rst|  26 +
 .../endpoint/function/binding/pci-test.txt|  19 -
 Documentation/PCI/endpoint/index.rst  |   2 +
 Documentation/admin-guide/sysctl/vm.rst   |   2 +-
 Documentation/arm/booting.rst |   2 +-
 Documentation/arm64/index.rst |   1 +
 Documentation/arm64/{perf.txt => perf.rst}|   7 +-
 Documentation/core-api/index.rst  |   6 +
 .../{mailbox.txt => core-api/mailbox.rst} |   0
 .../nommu-mmap.rst}   |   0
 .../this_cpu_ops.rst} |   0
 .../unaligned-memory-access.rst   |   0
 .../crypto/{api-intro.txt => api-intro.rst}   | 186 ++--
 ...symmetric-keys.txt => asymmetric-keys.rst} |  91 +-
 .../{async-tx-api.txt => async-tx-api.rst}| 253 +++---
 ...{descore-readme.txt => descore-readme.rst} | 152 +++-
 Documentation/crypto/index.rst|   5 +
 ...-without-of.txt => booting-without-of.rst} | 299 ---
 Documentation/devicetree/index.rst|   1 +
 Documentation/driver-api/dmaengine/client.rst |   2 +-
 .../driver-api/dmaengine/provider.rst |   2 +-
 .../driver-api/thermal/cpu-idle-cooling.rst   |  14 +-
 Documentation/gpu/drm-mm.rst  |   2 +-
 Documentation/index.rst   |  13 +
 .../{ad525x_dpot.txt => ad525x_dpot.rst}  |  24 +-
 .../{apds990x.txt => apds990x.rst}|  31 +-
 .../{bh1770glc.txt => bh1770glc.rst}  |  45 +-
 .../misc-devices/{c2port.txt => c2port.rst}   |  58 +-
 Documentation/misc-devices/index.rst  |   6 +
 .../misc-devices/pci-endpoint-test.rst|  56 ++
 .../misc-devices/pci-endpoint-test.txt|  41 -
 .../misc-devices/spear-pcie-gadget.rst| 170 
 .../misc-devices/spear-pcie-gadget.txt| 130 ---
 Documentation/powerpc/index.rst   |   1 +
 ...patch_stats.txt => vcpudispatch_stats.rst} |  17 +-
 Documentation/security/keys/core.rst  |   2 +-
 Documentation/sh/index.rst|   6 +
 .../sh/{new-machine.txt => new-machine.rst}   | 195 +++--
 ...{register-banks.txt => register-banks.rst} |  13 +-
 .../{crc32.txt => staging/crc32.rst}  |   0
 Documentation/staging/index.rst   |  59 ++
 .../{kprobes.txt => staging/kprobes.rst}  |   0
 Documentation/{lzo.txt => staging/lzo.rst}|   0
 .../remoteproc.rst}   |   2 +-
 .../{rpmsg.txt => staging/rpmsg.rst}  |   0
 .../speculation.rst}  |   8 +-
 .../static-keys.rst}  |   0
 Documentation/{tee.txt => staging/tee.rst}|   1 +
 Documentation/{xz.txt => staging/xz.rst}  |   0
 Documentation/trace/index.rst |   1 +
 Documentation/trace/kprobetrace.rst   |   2 +-
 ...ffer-design.txt => ring-buffer-design.rst} | 802 ++
 Documentation/translations/zh_CN/arm/Booting  |   2 +-
 MAINTAINERS   |  12 +-
 arch/Kconfig  |   2 +-
 arch/sh/Kconfig.cpu   |   2 +-
 crypto/asymmetric_keys/asymmetric_type.c  |   2 +-
 crypto/asymmetric_keys/public_key.c   |   2 +-
 crypto/asymmetric_keys/signature.c|   2 +-
 drivers/misc/Kconfig  |   2 +-
 drivers/misc/ad525x_dpot.c|   2 +-
 include/crypto/public_key

[PATCH 18/29] docs: powerpc: fix some issues at vas-api.rst

2020-06-15 Thread Mauro Carvalho Chehab
There are a few issues on this document, when built via the
building with ``make htmldocs``:

Documentation/powerpc/vas-api.rst:116: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:116: WARNING: Inline emphasis 
start-string without end-string.
Documentation/powerpc/vas-api.rst:117: WARNING: Block quote ends without a 
blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:117: WARNING: Inline emphasis 
start-string without end-string.
Documentation/powerpc/vas-api.rst:120: WARNING: Definition list ends 
without a blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:124: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:133: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:135: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:150: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:151: WARNING: Block quote ends without a 
blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:161: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:176: WARNING: Definition list ends 
without a blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:253: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:253: WARNING: Inline emphasis 
start-string without end-string.
Documentation/powerpc/vas-api.rst:259: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:261: WARNING: Block quote ends without a 
blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:266: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:267: WARNING: Block quote ends without a 
blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:270: WARNING: Definition list ends 
without a blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:271: WARNING: Definition list ends 
without a blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:273: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:274: WARNING: Block quote ends without a 
blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:277: WARNING: Definition list ends 
without a blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:278: WARNING: Definition list ends 
without a blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:280: WARNING: Unexpected indentation.
Documentation/powerpc/vas-api.rst:287: WARNING: Block quote ends without a 
blank line; unexpected unindent.
Documentation/powerpc/vas-api.rst:289: WARNING: Block quote ends without a 
blank line; unexpected unindent.

Fixes: c12e38b1d52e ("Documentation/powerpc: VAS API")
Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/powerpc/vas-api.rst | 23 ++-
 1 file changed, 18 insertions(+), 5 deletions(-)

diff --git a/Documentation/powerpc/vas-api.rst 
b/Documentation/powerpc/vas-api.rst
index 1217c2f1595e..b7fdbe560010 100644
--- a/Documentation/powerpc/vas-api.rst
+++ b/Documentation/powerpc/vas-api.rst
@@ -87,6 +87,7 @@ Applications may chose a specific instance of the NX 
co-processor using
 the vas_id field in the VAS_TX_WIN_OPEN ioctl as detailed below.
 
 A userspace library libnxz is available here but still in development:
+
 https://github.com/abalib/power-gzip
 
 Applications that use inflate / deflate calls can link with libnxz
@@ -110,6 +111,7 @@ Applications should use the VAS_TX_WIN_OPEN ioctl as 
follows to establish
 a connection with NX co-processor engine:
 
::
+
struct vas_tx_win_open_attr {
__u32   version;
__s16   vas_id; /* specific instance of vas or -1
@@ -119,8 +121,10 @@ a connection with NX co-processor engine:
__u64   reserved2[6];
};
 
-   version: The version field must be currently set to 1.
-   vas_id: If '-1' is passed, kernel will make a best-effort attempt
+   version:
+   The version field must be currently set to 1.
+   vas_id:
+   If '-1' is passed, kernel will make a best-effort attempt
to assign an optimal instance of NX for the process. To
select the specific VAS instance, refer
"Discovery of available VAS engines" section below.
@@ -129,7 +133,8 @@ a connection with NX co-processor engine:
and must be set to 0.
 
The attributes attr for the VAS_TX_WIN_OPEN ioctl are defined as
-   follows:
+   follows::
+
#define VAS_MAGIC 'v'
#define VAS_TX_WIN_OPEN _IOW(VAS_MAGIC, 1,
struct vas_tx_win_open_attr)
@@ -141,6 +146,8 @@ a connection with NX co-processor engine:
returns -1 and sets the errno variable to indicate the error.
 

[PATCH v4 00/19] Manually convert thermal, crypto and misc devices to ReST

2020-04-30 Thread Mauro Carvalho Chehab
Manually convert some files from thermal, crypto and misc-devices
to ReST format.

This series is against linux-next 20200430 tag (as I rebased it, in order
to check if some patch were already merged via some other tree),
but it should very likely merge fine against docs-next.

The full series (including those ones) are at:

https://git.linuxtv.org/mchehab/experimental.git/log/?h=misc-docs

The documents touched on this patch, converted to HTML via the 
building system are at (together with patches from other series):

https://www.infradead.org/~mchehab/kernel_docs/


v4:

- added some acks.

v3:

- removed the cpu-freq patches from this series, as Rafael should
  be applying it on his tree.

v2: 

- a small change at patch 2 to avoid uneeded whitespace changes;
- added 13 new patches at the end


Mauro Carvalho Chehab (19):
  docs: thermal: convert cpu-idle-cooling.rst to ReST
  docs: crypto: convert asymmetric-keys.txt to ReST
  docs: crypto: convert api-intro.txt to ReST format
  docs: crypto: convert async-tx-api.txt to ReST format
  docs: crypto: descore-readme.txt: convert to ReST format
  docs: misc-devices/spear-pcie-gadget.txt: convert to ReST
  docs: misc-devices/pci-endpoint-test.txt: convert to ReST
  docs: misc-devices/pci-endpoint-test.txt: convert to ReST
  docs: misc-devices/c2port.txt: convert to ReST format
  docs: misc-devices/bh1770glc.txt: convert to ReST
  docs: misc-devices/apds990x.txt: convert to ReST format
  docs: pci: endpoint/function/binding/pci-test.txt convert to ReST
  docs: arm64: convert perf.txt to ReST format
  docs: powerpc: convert vcpudispatch_stats.txt to ReST
  docs: sh: convert new-machine.txt to ReST
  docs: sh: convert register-banks.txt to ReST
  docs: trace: ring-buffer-design.txt: convert to ReST format
  docs: kvm: get read of devices/README
  docs: misc-devices: add uacce to the index.rst

 .../endpoint/function/binding/pci-test.rst|  26 +
 .../endpoint/function/binding/pci-test.txt|  19 -
 Documentation/PCI/endpoint/index.rst  |   2 +
 Documentation/arm64/index.rst |   1 +
 Documentation/arm64/{perf.txt => perf.rst}|   7 +-
 .../crypto/{api-intro.txt => api-intro.rst}   | 186 ++--
 ...symmetric-keys.txt => asymmetric-keys.rst} |  91 +-
 .../{async-tx-api.txt => async-tx-api.rst}| 253 +++---
 ...{descore-readme.txt => descore-readme.rst} | 152 +++-
 Documentation/crypto/index.rst|   5 +
 Documentation/driver-api/dmaengine/client.rst |   2 +-
 .../driver-api/dmaengine/provider.rst |   2 +-
 .../driver-api/thermal/cpu-idle-cooling.rst   |  18 +-
 Documentation/driver-api/thermal/index.rst|   1 +
 .../{ad525x_dpot.txt => ad525x_dpot.rst}  |  24 +-
 .../{apds990x.txt => apds990x.rst}|  31 +-
 .../{bh1770glc.txt => bh1770glc.rst}  |  45 +-
 .../misc-devices/{c2port.txt => c2port.rst}   |  58 +-
 Documentation/misc-devices/index.rst  |   7 +
 .../misc-devices/pci-endpoint-test.rst|  56 ++
 .../misc-devices/pci-endpoint-test.txt|  41 -
 .../misc-devices/spear-pcie-gadget.rst| 170 
 .../misc-devices/spear-pcie-gadget.txt| 130 ---
 Documentation/powerpc/index.rst   |   1 +
 ...patch_stats.txt => vcpudispatch_stats.rst} |  17 +-
 Documentation/security/keys/core.rst  |   2 +-
 Documentation/sh/index.rst|   6 +
 .../sh/{new-machine.txt => new-machine.rst}   | 195 +++--
 ...{register-banks.txt => register-banks.rst} |  13 +-
 Documentation/trace/index.rst |   1 +
 ...ffer-design.txt => ring-buffer-design.rst} | 802 ++
 Documentation/virt/kvm/devices/README |   1 -
 Documentation/virt/kvm/devices/index.rst  |   3 +
 MAINTAINERS   |   4 +-
 arch/sh/Kconfig.cpu   |   2 +-
 crypto/asymmetric_keys/asymmetric_type.c  |   2 +-
 crypto/asymmetric_keys/public_key.c   |   2 +-
 crypto/asymmetric_keys/signature.c|   2 +-
 drivers/misc/Kconfig  |   2 +-
 drivers/misc/ad525x_dpot.c|   2 +-
 include/crypto/public_key.h   |   2 +-
 include/keys/asymmetric-parser.h  |   2 +-
 include/keys/asymmetric-subtype.h |   2 +-
 include/keys/asymmetric-type.h|   2 +-
 44 files changed, 1358 insertions(+), 1034 deletions(-)
 create mode 100644 Documentation/PCI/endpoint/function/binding/pci-test.rst
 delete mode 100644 Documentation/PCI/endpoint/function/binding/pci-test.txt
 rename Documentation/arm64/{perf.txt => perf.rst} (95%)
 rename Documentation/crypto/{api-intro.txt => api-intro.rst} (70%)
 rename Documentation/crypto/{asymmetric-keys.txt => asymmetric-keys.rst} (91%)
 rename Documentation/crypto/{async-tx-api.txt => async-tx-api.rst} (55%)
 rename Documentation/crypto/{descore-readme.txt => descore-readme.rst} (81

[PATCH v4 14/19] docs: powerpc: convert vcpudispatch_stats.txt to ReST

2020-04-30 Thread Mauro Carvalho Chehab
- Add a SPDX header;
- Use standard markup for document title;
- Adjust identation on lists and add blank lines where
  needed;
- Add it to the powerpc index.rst file.

Acked-by: Michael Ellerman  # powerpc
Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/powerpc/index.rst |  1 +
 ...ispatch_stats.txt => vcpudispatch_stats.rst} | 17 -
 2 files changed, 13 insertions(+), 5 deletions(-)
 rename Documentation/powerpc/{vcpudispatch_stats.txt => 
vcpudispatch_stats.rst} (94%)

diff --git a/Documentation/powerpc/index.rst b/Documentation/powerpc/index.rst
index afe2d5e54db6..748bf483b1c2 100644
--- a/Documentation/powerpc/index.rst
+++ b/Documentation/powerpc/index.rst
@@ -31,6 +31,7 @@ powerpc
 transactional_memory
 ultravisor
 vas-api
+vcpudispatch_stats
 
 .. only::  subproject and html
 
diff --git a/Documentation/powerpc/vcpudispatch_stats.txt 
b/Documentation/powerpc/vcpudispatch_stats.rst
similarity index 94%
rename from Documentation/powerpc/vcpudispatch_stats.txt
rename to Documentation/powerpc/vcpudispatch_stats.rst
index e21476bfd78c..5704657a5987 100644
--- a/Documentation/powerpc/vcpudispatch_stats.txt
+++ b/Documentation/powerpc/vcpudispatch_stats.rst
@@ -1,5 +1,8 @@
-VCPU Dispatch Statistics:
-=
+.. SPDX-License-Identifier: GPL-2.0
+
+
+VCPU Dispatch Statistics
+
 
 For Shared Processor LPARs, the POWER Hypervisor maintains a relatively
 static mapping of the LPAR processors (vcpus) to physical processor
@@ -20,25 +23,29 @@ The statistics themselves are available by reading the 
procfs file
 a vcpu as represented by the first field, followed by 8 numbers.
 
 The first number corresponds to:
+
 1. total vcpu dispatches since the beginning of statistics collection
 
 The next 4 numbers represent vcpu dispatch dispersions:
+
 2. number of times this vcpu was dispatched on the same processor as last
time
 3. number of times this vcpu was dispatched on a different processor core
as last time, but within the same chip
 4. number of times this vcpu was dispatched on a different chip
 5. number of times this vcpu was dispatches on a different socket/drawer
-(next numa boundary)
+   (next numa boundary)
 
 The final 3 numbers represent statistics in relation to the home node of
 the vcpu:
+
 6. number of times this vcpu was dispatched in its home node (chip)
 7. number of times this vcpu was dispatched in a different node
 8. number of times this vcpu was dispatched in a node further away (numa
-distance)
+   distance)
+
+An example output::
 
-An example output:
 $ sudo cat /proc/powerpc/vcpudispatch_stats
 cpu0 6839 4126 2683 30 0 6821 18 0
 cpu1 2515 1274 1229 12 0 2509 6 0
-- 
2.25.4



[PATCH 07/37] docs: networking: convert netconsole.txt to ReST

2020-04-30 Thread Mauro Carvalho Chehab
- add SPDX header;
- add a document title;
- mark code blocks and literals as such;
- mark tables as such;
- add notes markups;
- adjust identation, whitespaces and blank lines;
- add to networking/index.rst.

Signed-off-by: Mauro Carvalho Chehab 
---
 .../admin-guide/kernel-parameters.txt |   2 +-
 Documentation/admin-guide/serial-console.rst  |   2 +-
 Documentation/networking/index.rst|   1 +
 .../{netconsole.txt => netconsole.rst}| 125 +++---
 drivers/net/Kconfig   |   4 +-
 drivers/net/ethernet/toshiba/ps3_gelic_net.c  |   2 +-
 drivers/net/ethernet/toshiba/spider_net.c |   2 +-
 7 files changed, 84 insertions(+), 54 deletions(-)
 rename Documentation/networking/{netconsole.txt => netconsole.rst} (66%)

diff --git a/Documentation/admin-guide/kernel-parameters.txt 
b/Documentation/admin-guide/kernel-parameters.txt
index 25644daa36ea..5a44c1bf85e7 100644
--- a/Documentation/admin-guide/kernel-parameters.txt
+++ b/Documentation/admin-guide/kernel-parameters.txt
@@ -638,7 +638,7 @@
 
See Documentation/admin-guide/serial-console.rst for 
more
information.  See
-   Documentation/networking/netconsole.txt for an
+   Documentation/networking/netconsole.rst for an
alternative.
 
uart[8250],io,[,options]
diff --git a/Documentation/admin-guide/serial-console.rst 
b/Documentation/admin-guide/serial-console.rst
index a8d1e36b627a..58b32832e50a 100644
--- a/Documentation/admin-guide/serial-console.rst
+++ b/Documentation/admin-guide/serial-console.rst
@@ -54,7 +54,7 @@ You will need to create a new device to use ``/dev/console``. 
The official
 ``/dev/console`` is now character device 5,1.
 
 (You can also use a network device as a console.  See
-``Documentation/networking/netconsole.txt`` for information on that.)
+``Documentation/networking/netconsole.rst`` for information on that.)
 
 Here's an example that will use ``/dev/ttyS1`` (COM2) as the console.
 Replace the sample values as needed.
diff --git a/Documentation/networking/index.rst 
b/Documentation/networking/index.rst
index 492658bf7c0d..e58f872d401d 100644
--- a/Documentation/networking/index.rst
+++ b/Documentation/networking/index.rst
@@ -80,6 +80,7 @@ Contents:
mac80211-injection
mpls-sysctl
multiqueue
+   netconsole
 
 .. only::  subproject and html
 
diff --git a/Documentation/networking/netconsole.txt 
b/Documentation/networking/netconsole.rst
similarity index 66%
rename from Documentation/networking/netconsole.txt
rename to Documentation/networking/netconsole.rst
index 296ea00fd3eb..1f5c4a04027c 100644
--- a/Documentation/networking/netconsole.txt
+++ b/Documentation/networking/netconsole.rst
@@ -1,7 +1,16 @@
+.. SPDX-License-Identifier: GPL-2.0
+
+==
+Netconsole
+==
+
 
 started by Ingo Molnar , 2001.09.17
+
 2.6 port and netpoll api by Matt Mackall , Sep 9 2003
+
 IPv6 support by Cong Wang , Jan 1 2013
+
 Extended console support by Tejun Heo , May 1 2015
 
 Please send bug reports to Matt Mackall 
@@ -23,34 +32,34 @@ Sender and receiver configuration:
 ==
 
 It takes a string configuration parameter "netconsole" in the
-following format:
+following format::
 
  netconsole=[+][src-port]@[src-ip]/[],[tgt-port]@/[tgt-macaddr]
 
where
-+ if present, enable extended console support
-src-port  source for UDP packets (defaults to 6665)
-src-ipsource IP to use (interface address)
-dev   network interface (eth0)
-tgt-port  port for logging agent ()
-tgt-ipIP address for logging agent
-tgt-macaddr   ethernet MAC address for logging agent (broadcast)
+   + if present, enable extended console support
+   src-port  source for UDP packets (defaults to 6665)
+   src-ipsource IP to use (interface address)
+   dev   network interface (eth0)
+   tgt-port  port for logging agent ()
+   tgt-ipIP address for logging agent
+   tgt-macaddr   ethernet MAC address for logging agent (broadcast)
 
-Examples:
+Examples::
 
  linux netconsole=@10.0.0.1/eth1,9353@10.0.0.2/12:34:56:78:9a:bc
 
-  or
+or::
 
  insmod netconsole netconsole=@/,@10.0.0.2/
 
-  or using IPv6
+or using IPv6::
 
  insmod netconsole netconsole=@/,@fd00:1:2:3::1/
 
 It also supports logging to multiple remote agents by specifying
 parameters for the multiple agents separated by semicolons and the
-complete string enclosed in "quotes", thusly:
+complete string enclosed in "quotes", thusly::
 
  modprobe netconsole netconsole="@/,@10.0.0.2/;@/eth1,6892@10.0.0.3/"
 
@@ -67,14 +76,19 @@ for example:
 
On distributions using a BSD-based netcat version (e.g. Fedora,
openSUSE and Ubuntu) the listening port must be s

[PATCH 00/37] net: manually convert files to ReST format - part 2

2020-04-30 Thread Mauro Carvalho Chehab
That's the second part of my work to convert the networking
text files into ReST. it is based on today's linux-next (next-20200430).

The full series (including those ones) are at:

https://git.linuxtv.org/mchehab/experimental.git/log/?h=net-docs

I should be sending the remaining patches (another /38 series)
after getting those merged at -next.

The documents, converted to HTML via the building system are at:

https://www.infradead.org/~mchehab/kernel_docs/networking/

Mauro Carvalho Chehab (37):
  docs: networking: convert l2tp.txt to ReST
  docs: networking: convert lapb-module.txt to ReST
  docs: networking: convert ltpc.txt to ReST
  docs: networking: convert mac80211-injection.txt to ReST
  docs: networking: convert mpls-sysctl.txt to ReST
  docs: networking: convert multiqueue.txt to ReST
  docs: networking: convert netconsole.txt to ReST
  docs: networking: convert netdev-features.txt to ReST
  docs: networking: convert netdevices.txt to ReST
  docs: networking: convert netfilter-sysctl.txt to ReST
  docs: networking: convert netif-msg.txt to ReST
  docs: networking: convert nf_conntrack-sysctl.txt to ReST
  docs: networking: convert nf_flowtable.txt to ReST
  docs: networking: convert openvswitch.txt to ReST
  docs: networking: convert operstates.txt to ReST
  docs: networking: convert packet_mmap.txt to ReST
  docs: networking: convert phonet.txt to ReST
  docs: networking: convert pktgen.txt to ReST
  docs: networking: convert PLIP.txt to ReST
  docs: networking: convert ppp_generic.txt to ReST
  docs: networking: convert proc_net_tcp.txt to ReST
  docs: networking: convert radiotap-headers.txt to ReST
  docs: networking: convert ray_cs.txt to ReST
  docs: networking: convert rds.txt to ReST
  docs: networking: convert regulatory.txt to ReST
  docs: networking: convert rxrpc.txt to ReST
  docs: networking: convert sctp.txt to ReST
  docs: networking: convert secid.txt to ReST
  docs: networking: convert seg6-sysctl.txt to ReST
  docs: networking: convert skfp.txt to ReST
  docs: networking: convert strparser.txt to ReST
  docs: networking: convert switchdev.txt to ReST
  docs: networking: convert tc-actions-env-rules.txt to ReST
  docs: networking: convert tcp-thin.txt to ReST
  docs: networking: convert team.txt to ReST
  docs: networking: convert timestamping.txt to ReST
  docs: networking: convert tproxy.txt to ReST

 .../admin-guide/kernel-parameters.txt |2 +-
 Documentation/admin-guide/serial-console.rst  |2 +-
 Documentation/filesystems/afs.rst |2 +-
 Documentation/networking/bonding.rst  |2 +-
 Documentation/networking/can.rst  |2 +-
 .../networking/checksum-offloads.rst  |2 +-
 Documentation/networking/index.rst|   37 +
 Documentation/networking/ip-sysctl.rst|2 +-
 .../networking/{l2tp.txt => l2tp.rst} |  145 ++-
 .../{lapb-module.txt => lapb-module.rst}  |  120 +-
 .../networking/{ltpc.txt => ltpc.rst} |   45 +-
 ...1-injection.txt => mac80211-injection.rst} |   41 +-
 .../{mpls-sysctl.txt => mpls-sysctl.rst}  |   17 +-
 .../{multiqueue.txt => multiqueue.rst}|   41 +-
 .../{netconsole.txt => netconsole.rst}|  125 +-
 ...etdev-features.txt => netdev-features.rst} |   19 +-
 .../{netdevices.txt => netdevices.rst}|   21 +-
 ...filter-sysctl.txt => netfilter-sysctl.rst} |   11 +-
 Documentation/networking/netif-msg.rst|   95 ++
 Documentation/networking/netif-msg.txt|   79 --
 ...ack-sysctl.txt => nf_conntrack-sysctl.rst} |   51 +-
 .../{nf_flowtable.txt => nf_flowtable.rst}|   55 +-
 .../{openvswitch.txt => openvswitch.rst}  |   23 +-
 .../{operstates.txt => operstates.rst}|   45 +-
 Documentation/networking/packet_mmap.rst  | 1084 +
 Documentation/networking/packet_mmap.txt  | 1061 
 .../networking/{phonet.txt => phonet.rst} |   56 +-
 .../networking/{pktgen.txt => pktgen.rst} |  316 ++---
 .../networking/{PLIP.txt => plip.rst} |   43 +-
 .../{ppp_generic.txt => ppp_generic.rst}  |   52 +-
 .../{proc_net_tcp.txt => proc_net_tcp.rst}|   23 +-
 ...iotap-headers.txt => radiotap-headers.rst} |   99 +-
 .../networking/{ray_cs.txt => ray_cs.rst} |  101 +-
 Documentation/networking/{rds.txt => rds.rst} |  295 +++--
 .../{regulatory.txt => regulatory.rst}|   29 +-
 .../networking/{rxrpc.txt => rxrpc.rst}   |  306 ++---
 .../networking/{sctp.txt => sctp.rst} |   37 +-
 .../networking/{secid.txt => secid.rst}   |6 +
 Documentation/networking/seg6-sysctl.rst  |   26 +
 Documentation/networking/seg6-sysctl.txt  |   18 -
 .../networking/{skfp.txt => skfp.rst} |  153 ++-
 .../{strparser.txt => strparser.rst}  |   85 +-
 .../{switchdev.txt => switchdev.rst}  |  114 +-
 .../networking/tc-act

[PATCH v3 23/29] docs: filesystems: convert spufs/spufs.txt to ReST

2020-04-27 Thread Mauro Carvalho Chehab
This file is at groff output format. Manually convert it to
ReST format, trying to preserve a similar output after parsed.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/filesystems/spufs/index.rst |  1 +
 .../spufs/{spufs.txt => spufs.rst}| 59 +--
 MAINTAINERS   |  2 +-
 3 files changed, 30 insertions(+), 32 deletions(-)
 rename Documentation/filesystems/spufs/{spufs.txt => spufs.rst} (95%)

diff --git a/Documentation/filesystems/spufs/index.rst 
b/Documentation/filesystems/spufs/index.rst
index 39553c6ebefd..939cf59a7d9e 100644
--- a/Documentation/filesystems/spufs/index.rst
+++ b/Documentation/filesystems/spufs/index.rst
@@ -8,4 +8,5 @@ SPU Filesystem
 .. toctree::
:maxdepth: 1
 
+   spufs
spu_create
diff --git a/Documentation/filesystems/spufs/spufs.txt 
b/Documentation/filesystems/spufs/spufs.rst
similarity index 95%
rename from Documentation/filesystems/spufs/spufs.txt
rename to Documentation/filesystems/spufs/spufs.rst
index caf36aaae804..8a42859bb100 100644
--- a/Documentation/filesystems/spufs/spufs.txt
+++ b/Documentation/filesystems/spufs/spufs.rst
@@ -1,12 +1,18 @@
-SPUFS(2)   Linux Programmer's Manual  SPUFS(2)
+.. SPDX-License-Identifier: GPL-2.0
 
+=
+spufs
+=
 
+Name
+
 
-NAME
spufs - the SPU file system
 
 
-DESCRIPTION
+Description
+===
+
The SPU file system is used on PowerPC machines that implement the Cell
Broadband Engine Architecture in order to access Synergistic  Processor
Units (SPUs).
@@ -21,7 +27,9 @@ DESCRIPTION
ally add or remove files.
 
 
-MOUNT OPTIONS
+Mount Options
+=
+
uid=
   set the user owning the mount point, the default is 0 (root).
 
@@ -29,7 +37,9 @@ MOUNT OPTIONS
   set the group owning the mount point, the default is 0 (root).
 
 
-FILES
+Files
+=
+
The files in spufs mostly follow the standard behavior for regular sys-
tem  calls like read(2) or write(2), but often support only a subset of
the operations supported on regular file systems. This list details the
@@ -125,14 +135,12 @@ FILES
   space is available for writing.
 
 
-   /mbox_stat
-   /ibox_stat
-   /wbox_stat
+   /mbox_stat, /ibox_stat, /wbox_stat
Read-only files that contain the length of the current queue, i.e.  how
many  words  can  be  read  from  mbox or ibox or how many words can be
written to wbox without blocking.  The files can be read only in 4-byte
units  and  return  a  big-endian  binary integer number.  The possible
-   operations on an open *box_stat file are:
+   operations on an open ``*box_stat`` file are:
 
read(2)
   If a count smaller than four is requested, read returns  -1  and
@@ -143,12 +151,7 @@ FILES
   in EAGAIN.
 
 
-   /npc
-   /decr
-   /decr_status
-   /spu_tag_mask
-   /event_mask
-   /srr0
+   /npc, /decr, /decr_status, /spu_tag_mask, /event_mask, /srr0
Internal  registers  of  the SPU. The representation is an ASCII string
with the numeric value of the next instruction to  be  executed.  These
can  be  used in read/write mode for debugging, but normal operation of
@@ -157,17 +160,14 @@ FILES
 
The contents of these files are:
 
+   === ===
npc Next Program Counter
-
decrSPU Decrementer
-
decr_status Decrementer Status
-
spu_tag_maskMFC tag mask for SPU DMA
-
event_mask  Event mask for SPU interrupts
-
srr0Interrupt Return address register
+   === ===
 
 
The   possible   operations   on   an   open  npc,  decr,  decr_status,
@@ -206,8 +206,7 @@ FILES
   from the data buffer, updating the value of the fpcr register.
 
 
-   /signal1
-   /signal2
+   /signal1, /signal2
The two signal notification channels of an SPU.  These  are  read-write
files  that  operate  on  a 32 bit word.  Writing to one of these files
triggers an interrupt on the SPU.  The  value  written  to  the  signal
@@ -233,8 +232,7 @@ FILES
   file.
 
 
-   /signal1_type
-   /signal2_type
+   /signal1_type, /signal2_type
These two files change the behavior of the signal1 and signal2  notifi-
cation  files.  The  contain  a numerical ASCII string which is read as
either "1" or "0".  In mode 0 (overwrite), the  hardware  replaces  the
@@ -259,18 +257,17 @@ FILES
   the previous setting.
 
 
-EXAMPLES
+Examples
+
/etc/fstab entry
   none  /spu  spufs gid=spu   00
 
 
-AUTHORS
+Authors
+===
Arnd  Bergmann  ,  Mark  Nutter ,
Ulrich Weig

[PATCH v3 00/29] Convert files to ReST - part 2

2020-04-27 Thread Mauro Carvalho Chehab
This is the second part of a series I wrote sometime ago where I manually
convert lots of files to be properly parsed by Sphinx as ReST files.

As it touches on lot of stuff, this series is based on today's linux-next, 
at tag next-20190617.

The first version of this series had 57 patches. The first part with 28 patches
were already merged. Right now, there are still ~76  patches pending applying
(including this series), and that's because I opted to do ~1 patch per converted
 directory.

That sounds too much to be send on a single round. So, I'm opting to split
it on 3 parts for the conversion, plus a final patch adding orphaned books
to existing ones. 

Those patches should probably be good to be merged either by subsystem
maintainers or via the docs tree.

I opted to mark new files not included yet to the main index.rst (directly or
indirectly) with the :orphan: tag, in order to avoid adding warnings to the
build system. This should be removed after we find a "home" for all
the converted files within the new document tree arrangement, after I
submit the third part.

Both this series and  the other parts of this work are on my devel git tree,
at:


https://git.linuxtv.org/mchehab/experimental.git/log/?h=convert_rst_renames_v5.1

The final output in html (after all patches I currently have, including 
the upcoming series) can be seen at:

https://www.infradead.org/~mchehab/rst_conversion/

It contains all pending work from my side related to the conversion, plus
the patches I finished a first version today with contains the renaming 
patches and de-orphan changes.

---

Version 3:

- Rebased on the top of next-20200424
- configfs.rst conversion moved to the end of the series;
- avoided almost all markups at configfs.rst while still preserving
  a reasonable output and not generating build warnings.

Version 2:

- Removed patches merged via other trees;
- rebased on the top of today's linux-next (next-20190617);
- Fix a typo on one patch's description;
- Added received acks.

Mauro Carvalho Chehab (29):
  docs: filesystems: convert caching/object.txt to ReST
  docs: filesystems: convert caching/fscache.txt to ReST format
  docs: filesystems: caching/netfs-api.txt: convert it to ReST
  docs: filesystems: caching/operations.txt: convert it to ReST
  docs: filesystems: caching/cachefiles.txt: convert to ReST
  docs: filesystems: caching/backend-api.txt: convert it to ReST
  docs: filesystems: convert cifs/cifsroot.txt to ReST
  docs: filesystems: convert automount-support.txt to ReST
  docs: filesystems: convert coda.txt to ReST
  docs: filesystems: convert devpts.txt to ReST
  docs: filesystems: convert dnotify.txt to ReST
  docs: filesystems: convert fiemap.txt to ReST
  docs: filesystems: convert files.txt to ReST
  docs: filesystems: convert fuse-io.txt to ReST
  docs: filesystems: convert locks.txt to ReST
  docs: filesystems: convert mandatory-locking.txt to ReST
  docs: filesystems: convert mount_api.txt to ReST
  docs: filesystems: convert quota.txt to ReST
  docs: filesystems: convert seq_file.txt to ReST
  docs: filesystems: convert sharedsubtree.txt to ReST
  docs: filesystems: split spufs.txt into 3 separate files
  docs: filesystems: convert spufs/spu_create.txt to ReST
  docs: filesystems: convert spufs/spufs.txt to ReST
  docs: filesystems: convert spufs/spu_run.txt to ReST
  docs: filesystems: convert sysfs-pci.txt to ReST
  docs: filesystems: convert sysfs-tagging.txt to ReST
  docs: filesystems: convert xfs-delayed-logging-design.txt to ReST
  docs: filesystems: convert xfs-self-describing-metadata.txt to ReST
  docs: filesystems: convert configfs.txt to ReST

 Documentation/admin-guide/sysctl/kernel.rst   |2 +-
 ...ount-support.txt => automount-support.rst} |   23 +-
 .../{backend-api.txt => backend-api.rst}  |  165 +-
 .../{cachefiles.txt => cachefiles.rst}|  139 +-
 Documentation/filesystems/caching/fscache.rst |  565 ++
 Documentation/filesystems/caching/fscache.txt |  448 -
 Documentation/filesystems/caching/index.rst   |   14 +
 .../caching/{netfs-api.txt => netfs-api.rst}  |  172 +-
 .../caching/{object.txt => object.rst}|   43 +-
 .../{operations.txt => operations.rst}|   45 +-
 .../cifs/{cifsroot.txt => cifsroot.rst}   |   56 +-
 Documentation/filesystems/coda.rst| 1670 
 Documentation/filesystems/coda.txt| 1676 -
 .../{configfs/configfs.txt => configfs.rst}   |  131 +-
 Documentation/filesystems/devpts.rst  |   36 +
 Documentation/filesystems/devpts.txt  |   26 -
 .../filesystems/{dnotify.txt => dnotify.rst}  |   11 +-
 .../filesystems/{fiemap.txt => fiemap.rst}|  133 +-
 .../filesystems/{files.txt => files.rst}  |   15 +-
 .../filesystems/{fuse-io.txt => fuse-io.rst}  |6 +
 Documentation/filesystems/index.rst   |   23 +
 .../filesystems/{locks.txt => locks.rst}  |   14 +-
 ...

[PATCH v2 24/29] docs: filesystems: convert spufs/spufs.txt to ReST

2020-04-21 Thread Mauro Carvalho Chehab
This file is at groff output format. Manually convert it to
ReST format, trying to preserve a similar output after parsed.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/filesystems/spufs/index.rst |  1 +
 .../spufs/{spufs.txt => spufs.rst}| 59 +--
 MAINTAINERS   |  2 +-
 3 files changed, 30 insertions(+), 32 deletions(-)
 rename Documentation/filesystems/spufs/{spufs.txt => spufs.rst} (95%)

diff --git a/Documentation/filesystems/spufs/index.rst 
b/Documentation/filesystems/spufs/index.rst
index 39553c6ebefd..939cf59a7d9e 100644
--- a/Documentation/filesystems/spufs/index.rst
+++ b/Documentation/filesystems/spufs/index.rst
@@ -8,4 +8,5 @@ SPU Filesystem
 .. toctree::
:maxdepth: 1
 
+   spufs
spu_create
diff --git a/Documentation/filesystems/spufs/spufs.txt 
b/Documentation/filesystems/spufs/spufs.rst
similarity index 95%
rename from Documentation/filesystems/spufs/spufs.txt
rename to Documentation/filesystems/spufs/spufs.rst
index caf36aaae804..8a42859bb100 100644
--- a/Documentation/filesystems/spufs/spufs.txt
+++ b/Documentation/filesystems/spufs/spufs.rst
@@ -1,12 +1,18 @@
-SPUFS(2)   Linux Programmer's Manual  SPUFS(2)
+.. SPDX-License-Identifier: GPL-2.0
 
+=
+spufs
+=
 
+Name
+
 
-NAME
spufs - the SPU file system
 
 
-DESCRIPTION
+Description
+===
+
The SPU file system is used on PowerPC machines that implement the Cell
Broadband Engine Architecture in order to access Synergistic  Processor
Units (SPUs).
@@ -21,7 +27,9 @@ DESCRIPTION
ally add or remove files.
 
 
-MOUNT OPTIONS
+Mount Options
+=
+
uid=
   set the user owning the mount point, the default is 0 (root).
 
@@ -29,7 +37,9 @@ MOUNT OPTIONS
   set the group owning the mount point, the default is 0 (root).
 
 
-FILES
+Files
+=
+
The files in spufs mostly follow the standard behavior for regular sys-
tem  calls like read(2) or write(2), but often support only a subset of
the operations supported on regular file systems. This list details the
@@ -125,14 +135,12 @@ FILES
   space is available for writing.
 
 
-   /mbox_stat
-   /ibox_stat
-   /wbox_stat
+   /mbox_stat, /ibox_stat, /wbox_stat
Read-only files that contain the length of the current queue, i.e.  how
many  words  can  be  read  from  mbox or ibox or how many words can be
written to wbox without blocking.  The files can be read only in 4-byte
units  and  return  a  big-endian  binary integer number.  The possible
-   operations on an open *box_stat file are:
+   operations on an open ``*box_stat`` file are:
 
read(2)
   If a count smaller than four is requested, read returns  -1  and
@@ -143,12 +151,7 @@ FILES
   in EAGAIN.
 
 
-   /npc
-   /decr
-   /decr_status
-   /spu_tag_mask
-   /event_mask
-   /srr0
+   /npc, /decr, /decr_status, /spu_tag_mask, /event_mask, /srr0
Internal  registers  of  the SPU. The representation is an ASCII string
with the numeric value of the next instruction to  be  executed.  These
can  be  used in read/write mode for debugging, but normal operation of
@@ -157,17 +160,14 @@ FILES
 
The contents of these files are:
 
+   === ===
npc Next Program Counter
-
decrSPU Decrementer
-
decr_status Decrementer Status
-
spu_tag_maskMFC tag mask for SPU DMA
-
event_mask  Event mask for SPU interrupts
-
srr0Interrupt Return address register
+   === ===
 
 
The   possible   operations   on   an   open  npc,  decr,  decr_status,
@@ -206,8 +206,7 @@ FILES
   from the data buffer, updating the value of the fpcr register.
 
 
-   /signal1
-   /signal2
+   /signal1, /signal2
The two signal notification channels of an SPU.  These  are  read-write
files  that  operate  on  a 32 bit word.  Writing to one of these files
triggers an interrupt on the SPU.  The  value  written  to  the  signal
@@ -233,8 +232,7 @@ FILES
   file.
 
 
-   /signal1_type
-   /signal2_type
+   /signal1_type, /signal2_type
These two files change the behavior of the signal1 and signal2  notifi-
cation  files.  The  contain  a numerical ASCII string which is read as
either "1" or "0".  In mode 0 (overwrite), the  hardware  replaces  the
@@ -259,18 +257,17 @@ FILES
   the previous setting.
 
 
-EXAMPLES
+Examples
+
/etc/fstab entry
   none  /spu  spufs gid=spu   00
 
 
-AUTHORS
+Authors
+===
Arnd  Bergmann  ,  Mark  Nutter ,
Ulrich Weig

[PATCH v2 00/29] fs: convert remaining docs to ReST file format

2020-04-21 Thread Mauro Carvalho Chehab
This patch series convert the remaining files under Documentation/filesystems
to the ReST file format (except for dax.txt and patch-lookup.txt). 

It is based on linux-next (next-2020021).

PS.: I opted to add mainly ML from the output of get_maintainers.pl to the c/c
list of patch 00/34, because  otherwise the number of c/c would be too many,
with would very likely cause ML servers to reject it.

The results of those changes (together with other changes from my pending
doc patches) are available at:

   https://www.infradead.org/~mchehab/kernel_docs/filesystems/index.html

And the series is also on my git tree:

  https://git.linuxtv.org/mchehab/experimental.git/log/?h=fs_docs

If you prefer, feel free to merge the patches via the filesystems git tree(s).

- 

v2:

   - Removed dax.txt, in order to prevent a merge conflict with a dax patchset;
   - Removed patch-lookup.txt conversion, due to patch-lookup.rst.
 (I'll revisit this on some future)
   - Removed a patch that was already merged;
   - Added some Acked-by.


Mauro Carvalho Chehab (29):
  docs: filesystems: convert caching/object.txt to ReST
  docs: filesystems: convert caching/fscache.txt to ReST format
  docs: filesystems: caching/netfs-api.txt: convert it to ReST
  docs: filesystems: caching/operations.txt: convert it to ReST
  docs: filesystems: caching/cachefiles.txt: convert to ReST
  docs: filesystems: caching/backend-api.txt: convert it to ReST
  docs: filesystems: convert cifs/cifsroot.txt to ReST
  docs: filesystems: convert configfs.txt to ReST
  docs: filesystems: convert automount-support.txt to ReST
  docs: filesystems: convert coda.txt to ReST
  docs: filesystems: convert devpts.txt to ReST
  docs: filesystems: convert dnotify.txt to ReST
  docs: filesystems: convert fiemap.txt to ReST
  docs: filesystems: convert files.txt to ReST
  docs: filesystems: convert fuse-io.txt to ReST
  docs: filesystems: convert locks.txt to ReST
  docs: filesystems: convert mandatory-locking.txt to ReST
  docs: filesystems: convert mount_api.txt to ReST
  docs: filesystems: convert quota.txt to ReST
  docs: filesystems: convert seq_file.txt to ReST
  docs: filesystems: convert sharedsubtree.txt to ReST
  docs: filesystems: split spufs.txt into 3 separate files
  docs: filesystems: convert spufs/spu_create.txt to ReST
  docs: filesystems: convert spufs/spufs.txt to ReST
  docs: filesystems: convert spufs/spu_run.txt to ReST
  docs: filesystems: convert sysfs-pci.txt to ReST
  docs: filesystems: convert sysfs-tagging.txt to ReST
  docs: filesystems: convert xfs-delayed-logging-design.txt to ReST
  docs: filesystems: convert xfs-self-describing-metadata.txt to ReST

 Documentation/admin-guide/sysctl/kernel.rst   |2 +-
 ...ount-support.txt => automount-support.rst} |   23 +-
 .../{backend-api.txt => backend-api.rst}  |  165 +-
 .../{cachefiles.txt => cachefiles.rst}|  139 +-
 Documentation/filesystems/caching/fscache.rst |  565 ++
 Documentation/filesystems/caching/fscache.txt |  448 -
 Documentation/filesystems/caching/index.rst   |   14 +
 .../caching/{netfs-api.txt => netfs-api.rst}  |  172 +-
 .../caching/{object.txt => object.rst}|   43 +-
 .../{operations.txt => operations.rst}|   45 +-
 .../cifs/{cifsroot.txt => cifsroot.rst}   |   56 +-
 Documentation/filesystems/coda.rst| 1670 
 Documentation/filesystems/coda.txt| 1676 -
 .../{configfs/configfs.txt => configfs.rst}   |  129 +-
 Documentation/filesystems/devpts.rst  |   36 +
 Documentation/filesystems/devpts.txt  |   26 -
 .../filesystems/{dnotify.txt => dnotify.rst}  |   11 +-
 .../filesystems/{fiemap.txt => fiemap.rst}|  133 +-
 .../filesystems/{files.txt => files.rst}  |   15 +-
 .../filesystems/{fuse-io.txt => fuse-io.rst}  |6 +
 Documentation/filesystems/index.rst   |   23 +
 .../filesystems/{locks.txt => locks.rst}  |   14 +-
 ...tory-locking.txt => mandatory-locking.rst} |   25 +-
 .../{mount_api.txt => mount_api.rst}  |  329 ++--
 Documentation/filesystems/proc.rst|2 +-
 .../filesystems/{quota.txt => quota.rst}  |   41 +-
 .../{seq_file.txt => seq_file.rst}|   61 +-
 .../{sharedsubtree.txt => sharedsubtree.rst}  |  394 ++--
 Documentation/filesystems/spufs/index.rst |   13 +
 .../filesystems/spufs/spu_create.rst  |  131 ++
 Documentation/filesystems/spufs/spu_run.rst   |  138 ++
 .../{spufs.txt => spufs/spufs.rst}|  304 +--
 .../{sysfs-pci.txt => sysfs-pci.rst}  |   23 +-
 .../{sysfs-tagging.txt => sysfs-tagging.rst}  |   22 +-
 ...ign.txt => xfs-delayed-logging-design.rst} |   65 +-
 ...a.txt => xfs-self-describing-metadata.rst} |  182 +-
 Documentation/iio/iio_configfs.rst|2 +-
 Documentation/usb/gadget_configfs.rst |4 +-
 MAINTAINERS   |   14

[PATCH 01/34] docs: filesystems: fix references for doc files there

2020-04-15 Thread Mauro Carvalho Chehab
Several files there were renamed to ReST. Fix the broken
references.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/ABI/stable/sysfs-devices-node   | 2 +-
 Documentation/ABI/testing/procfs-smaps_rollup | 2 +-
 Documentation/admin-guide/cpu-load.rst| 2 +-
 Documentation/admin-guide/nfs/nfsroot.rst | 2 +-
 Documentation/driver-api/driver-model/device.rst  | 2 +-
 Documentation/driver-api/driver-model/overview.rst| 2 +-
 Documentation/filesystems/dax.txt | 2 +-
 Documentation/filesystems/dnotify.txt | 2 +-
 Documentation/filesystems/ramfs-rootfs-initramfs.rst  | 2 +-
 Documentation/powerpc/firmware-assisted-dump.rst  | 2 +-
 Documentation/process/adding-syscalls.rst | 2 +-
 .../translations/it_IT/process/adding-syscalls.rst| 2 +-
 Documentation/translations/zh_CN/filesystems/sysfs.txt| 6 +++---
 drivers/gpu/drm/msm/disp/dpu1/dpu_kms.h   | 2 +-
 fs/Kconfig| 2 +-
 fs/Kconfig.binfmt | 2 +-
 fs/adfs/Kconfig   | 2 +-
 fs/affs/Kconfig   | 2 +-
 fs/afs/Kconfig| 6 +++---
 fs/bfs/Kconfig| 2 +-
 fs/cramfs/Kconfig | 2 +-
 fs/ecryptfs/Kconfig   | 2 +-
 fs/fat/Kconfig| 8 
 fs/fuse/Kconfig   | 2 +-
 fs/fuse/dev.c | 2 +-
 fs/hfs/Kconfig| 2 +-
 fs/hpfs/Kconfig   | 2 +-
 fs/isofs/Kconfig  | 2 +-
 fs/namespace.c| 2 +-
 fs/notify/inotify/Kconfig | 2 +-
 fs/ntfs/Kconfig   | 2 +-
 fs/ocfs2/Kconfig  | 2 +-
 fs/overlayfs/Kconfig  | 6 +++---
 fs/proc/Kconfig   | 4 ++--
 fs/romfs/Kconfig  | 2 +-
 fs/sysfs/dir.c| 2 +-
 fs/sysfs/file.c   | 2 +-
 fs/sysfs/mount.c  | 2 +-
 fs/sysfs/symlink.c| 2 +-
 fs/sysv/Kconfig   | 2 +-
 fs/udf/Kconfig| 2 +-
 include/linux/relay.h | 2 +-
 include/linux/sysfs.h | 2 +-
 kernel/relay.c| 2 +-
 44 files changed, 54 insertions(+), 54 deletions(-)

diff --git a/Documentation/ABI/stable/sysfs-devices-node 
b/Documentation/ABI/stable/sysfs-devices-node
index df8413cf1468..484fc04bcc25 100644
--- a/Documentation/ABI/stable/sysfs-devices-node
+++ b/Documentation/ABI/stable/sysfs-devices-node
@@ -54,7 +54,7 @@ Date: October 2002
 Contact:   Linux Memory Management list 
 Description:
Provides information about the node's distribution and memory
-   utilization. Similar to /proc/meminfo, see 
Documentation/filesystems/proc.txt
+   utilization. Similar to /proc/meminfo, see 
Documentation/filesystems/proc.rst
 
 What:  /sys/devices/system/node/nodeX/numastat
 Date:  October 2002
diff --git a/Documentation/ABI/testing/procfs-smaps_rollup 
b/Documentation/ABI/testing/procfs-smaps_rollup
index 274df44d8b1b..046978193368 100644
--- a/Documentation/ABI/testing/procfs-smaps_rollup
+++ b/Documentation/ABI/testing/procfs-smaps_rollup
@@ -11,7 +11,7 @@ Description:
Additionally, the fields Pss_Anon, Pss_File and Pss_Shmem
are not present in /proc/pid/smaps.  These fields represent
the sum of the Pss field of each type (anon, file, shmem).
-   For more details, see Documentation/filesystems/proc.txt
+   For more details, see Documentation/filesystems/proc.rst
and the procfs man page.
 
Typical output looks like this:
diff --git a/Documentation/admin-guide/cpu-load.rst 
b/Documentation/admin-guide/cpu-load.rst
index 2d01ce43d2a2..ebdecf864080 100644
--- a/Documentation/admin-guide/cpu-load.rst
+++ b/Documentation/admin-guide/cpu-load.rst
@@ -105,7 +105,7 @@ References
 --
 
 - http://lkml.org/lkml/2007/2/12/6
-- Documentation/filesystems/proc.txt (1.8)
+- Documentation/filesystems/proc.rst (1.8)
 
 
 Thanks
diff --git a/Documentation/admin-guide/nfs/nfsroot.rst

[PATCH 29/34] docs: filesystems: convert spufs/spufs.txt to ReST

2020-04-15 Thread Mauro Carvalho Chehab
This file is at groff output format. Manually convert it to
ReST format, trying to preserve a similar output after parsed.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/filesystems/spufs/index.rst |  1 +
 .../spufs/{spufs.txt => spufs.rst}| 59 +--
 MAINTAINERS   |  2 +-
 3 files changed, 30 insertions(+), 32 deletions(-)
 rename Documentation/filesystems/spufs/{spufs.txt => spufs.rst} (95%)

diff --git a/Documentation/filesystems/spufs/index.rst 
b/Documentation/filesystems/spufs/index.rst
index 39553c6ebefd..939cf59a7d9e 100644
--- a/Documentation/filesystems/spufs/index.rst
+++ b/Documentation/filesystems/spufs/index.rst
@@ -8,4 +8,5 @@ SPU Filesystem
 .. toctree::
:maxdepth: 1
 
+   spufs
spu_create
diff --git a/Documentation/filesystems/spufs/spufs.txt 
b/Documentation/filesystems/spufs/spufs.rst
similarity index 95%
rename from Documentation/filesystems/spufs/spufs.txt
rename to Documentation/filesystems/spufs/spufs.rst
index caf36aaae804..8a42859bb100 100644
--- a/Documentation/filesystems/spufs/spufs.txt
+++ b/Documentation/filesystems/spufs/spufs.rst
@@ -1,12 +1,18 @@
-SPUFS(2)   Linux Programmer's Manual  SPUFS(2)
+.. SPDX-License-Identifier: GPL-2.0
 
+=
+spufs
+=
 
+Name
+
 
-NAME
spufs - the SPU file system
 
 
-DESCRIPTION
+Description
+===
+
The SPU file system is used on PowerPC machines that implement the Cell
Broadband Engine Architecture in order to access Synergistic  Processor
Units (SPUs).
@@ -21,7 +27,9 @@ DESCRIPTION
ally add or remove files.
 
 
-MOUNT OPTIONS
+Mount Options
+=
+
uid=
   set the user owning the mount point, the default is 0 (root).
 
@@ -29,7 +37,9 @@ MOUNT OPTIONS
   set the group owning the mount point, the default is 0 (root).
 
 
-FILES
+Files
+=
+
The files in spufs mostly follow the standard behavior for regular sys-
tem  calls like read(2) or write(2), but often support only a subset of
the operations supported on regular file systems. This list details the
@@ -125,14 +135,12 @@ FILES
   space is available for writing.
 
 
-   /mbox_stat
-   /ibox_stat
-   /wbox_stat
+   /mbox_stat, /ibox_stat, /wbox_stat
Read-only files that contain the length of the current queue, i.e.  how
many  words  can  be  read  from  mbox or ibox or how many words can be
written to wbox without blocking.  The files can be read only in 4-byte
units  and  return  a  big-endian  binary integer number.  The possible
-   operations on an open *box_stat file are:
+   operations on an open ``*box_stat`` file are:
 
read(2)
   If a count smaller than four is requested, read returns  -1  and
@@ -143,12 +151,7 @@ FILES
   in EAGAIN.
 
 
-   /npc
-   /decr
-   /decr_status
-   /spu_tag_mask
-   /event_mask
-   /srr0
+   /npc, /decr, /decr_status, /spu_tag_mask, /event_mask, /srr0
Internal  registers  of  the SPU. The representation is an ASCII string
with the numeric value of the next instruction to  be  executed.  These
can  be  used in read/write mode for debugging, but normal operation of
@@ -157,17 +160,14 @@ FILES
 
The contents of these files are:
 
+   === ===
npc Next Program Counter
-
decrSPU Decrementer
-
decr_status Decrementer Status
-
spu_tag_maskMFC tag mask for SPU DMA
-
event_mask  Event mask for SPU interrupts
-
srr0Interrupt Return address register
+   === ===
 
 
The   possible   operations   on   an   open  npc,  decr,  decr_status,
@@ -206,8 +206,7 @@ FILES
   from the data buffer, updating the value of the fpcr register.
 
 
-   /signal1
-   /signal2
+   /signal1, /signal2
The two signal notification channels of an SPU.  These  are  read-write
files  that  operate  on  a 32 bit word.  Writing to one of these files
triggers an interrupt on the SPU.  The  value  written  to  the  signal
@@ -233,8 +232,7 @@ FILES
   file.
 
 
-   /signal1_type
-   /signal2_type
+   /signal1_type, /signal2_type
These two files change the behavior of the signal1 and signal2  notifi-
cation  files.  The  contain  a numerical ASCII string which is read as
either "1" or "0".  In mode 0 (overwrite), the  hardware  replaces  the
@@ -259,18 +257,17 @@ FILES
   the previous setting.
 
 
-EXAMPLES
+Examples
+
/etc/fstab entry
   none  /spu  spufs gid=spu   00
 
 
-AUTHORS
+Authors
+===
Arnd  Bergmann  ,  Mark  Nutter ,
Ulrich Weig

[PATCH 00/34] fs: convert remaining docs to ReST file format

2020-04-15 Thread Mauro Carvalho Chehab
This patch series convert the remaining files under Documentation/filesystems
to the ReST file format. It is based on linux-next (next-20200414).

PS.: I opted to add mainly ML from the output of get_maintainers.pl to the c/c
list of patch 00/34, because  otherwise the number of c/c would be too many,
with would very likely cause ML servers to reject it.

The results of those changes (together with other changes from my pending
doc patches) are available at:

   https://www.infradead.org/~mchehab/kernel_docs/filesystems/index.html

Mauro Carvalho Chehab (34):
  docs: filesystems: fix references for doc files there
  docs: filesystems: convert caching/object.txt to ReST
  docs: filesystems: convert caching/fscache.txt to ReST format
  docs: filesystems: caching/netfs-api.txt: convert it to ReST
  docs: filesystems: caching/operations.txt: convert it to ReST
  docs: filesystems: caching/cachefiles.txt: convert to ReST
  docs: filesystems: caching/backend-api.txt: convert it to ReST
  docs: filesystems: convert cifs/cifsroot.rst to ReST
  docs: filesystems: convert configfs.txt to ReST
  docs: filesystems: convert automount-support.txt to ReST
  docs: filesystems: convert coda.txt to ReST
  docs: filesystems: convert dax.txt to ReST
  docs: filesystems: convert devpts.txt to ReST
  docs: filesystems: convert dnotify.txt to ReST
  docs: filesystems: convert fiemap.txt to ReST
  docs: filesystems: convert files.txt to ReST
  docs: filesystems: convert fuse-io.txt to ReST
  docs: filesystems: convert gfs2-glocks.txt to ReST
  docs: filesystems: convert locks.txt to ReST
  docs: filesystems: convert mandatory-locking.txt to ReST
  docs: filesystems: convert mount_api.txt to ReST
  docs: filesystems: rename path-lookup.txt file
  docs: filesystems: convert path-walking.txt to ReST
  docs: filesystems: convert quota.txt to ReST
  docs: filesystems: convert seq_file.txt to ReST
  docs: filesystems: convert sharedsubtree.txt to ReST
  docs: filesystems: split spufs.txt into 3 separate files
  docs: filesystems: convert spufs/spu_create.txt to ReST
  docs: filesystems: convert spufs/spufs.txt to ReST
  docs: filesystems: convert spufs/spu_run.txt to ReST
  docs: filesystems: convert sysfs-pci.txt to ReST
  docs: filesystems: convert sysfs-tagging.txt to ReST
  docs: filesystems: convert xfs-delayed-logging-design.txt to ReST
  docs: filesystems: convert xfs-self-describing-metadata.txt to ReST

 Documentation/ABI/stable/sysfs-devices-node   |2 +-
 Documentation/ABI/testing/procfs-smaps_rollup |2 +-
 Documentation/admin-guide/cpu-load.rst|2 +-
 Documentation/admin-guide/ext4.rst|2 +-
 Documentation/admin-guide/nfs/nfsroot.rst |2 +-
 Documentation/admin-guide/sysctl/kernel.rst   |2 +-
 .../driver-api/driver-model/device.rst|2 +-
 .../driver-api/driver-model/overview.rst  |2 +-
 ...ount-support.txt => automount-support.rst} |   23 +-
 .../{backend-api.txt => backend-api.rst}  |  165 +-
 .../{cachefiles.txt => cachefiles.rst}|  139 +-
 Documentation/filesystems/caching/fscache.rst |  565 ++
 Documentation/filesystems/caching/fscache.txt |  448 -
 Documentation/filesystems/caching/index.rst   |   14 +
 .../caching/{netfs-api.txt => netfs-api.rst}  |  172 +-
 .../caching/{object.txt => object.rst}|   43 +-
 .../{operations.txt => operations.rst}|   45 +-
 .../cifs/{cifsroot.txt => cifsroot.rst}   |   56 +-
 Documentation/filesystems/coda.rst| 1670 
 Documentation/filesystems/coda.txt| 1676 -
 .../{configfs/configfs.txt => configfs.rst}   |  129 +-
 .../filesystems/{dax.txt => dax.rst}  |   11 +-
 Documentation/filesystems/devpts.rst  |   36 +
 Documentation/filesystems/devpts.txt  |   26 -
 .../filesystems/{dnotify.txt => dnotify.rst}  |   13 +-
 Documentation/filesystems/ext2.rst|2 +-
 .../filesystems/{fiemap.txt => fiemap.rst}|  133 +-
 .../filesystems/{files.txt => files.rst}  |   15 +-
 .../filesystems/{fuse-io.txt => fuse-io.rst}  |6 +
 .../{gfs2-glocks.txt => gfs2-glocks.rst}  |  147 +-
 Documentation/filesystems/index.rst   |   26 +
 .../filesystems/{locks.txt => locks.rst}  |   14 +-
 ...tory-locking.txt => mandatory-locking.rst} |   25 +-
 .../{mount_api.txt => mount_api.rst}  |  329 ++--
 .../{path-lookup.txt => path-walking.rst} |   88 +-
 Documentation/filesystems/porting.rst |2 +-
 Documentation/filesystems/proc.rst|2 +-
 .../filesystems/{quota.txt => quota.rst}  |   41 +-
 .../filesystems/ramfs-rootfs-initramfs.rst|2 +-
 .../{seq_file.txt => seq_file.rst}|   61 +-
 .../{sharedsubtree.txt => sharedsubtree.rst}  |  394 ++--
 Documentation/filesystems/spufs/index.rst |   13 +
 .../filesystems/spufs/spu_create.rst  |  131 ++
 Documentation/fil

[PATCH v2 11/33] docs: filesystems: fix renamed references

2020-04-14 Thread Mauro Carvalho Chehab
Some filesystem references got broken by a previous patch
series I submitted. Address those.

Signed-off-by: Mauro Carvalho Chehab 
Acked-by: David Sterba  # fs/affs/Kconfig
---
 Documentation/ABI/stable/sysfs-devices-node | 2 +-
 Documentation/ABI/testing/procfs-smaps_rollup   | 2 +-
 Documentation/admin-guide/cpu-load.rst  | 2 +-
 Documentation/admin-guide/nfs/nfsroot.rst   | 2 +-
 Documentation/driver-api/driver-model/device.rst| 4 ++--
 Documentation/driver-api/driver-model/overview.rst  | 2 +-
 Documentation/filesystems/dax.txt   | 2 +-
 Documentation/filesystems/dnotify.txt   | 2 +-
 Documentation/filesystems/ramfs-rootfs-initramfs.rst| 2 +-
 Documentation/filesystems/sysfs.rst | 2 +-
 Documentation/powerpc/firmware-assisted-dump.rst| 2 +-
 Documentation/process/adding-syscalls.rst   | 2 +-
 .../translations/it_IT/process/adding-syscalls.rst  | 2 +-
 Documentation/translations/zh_CN/filesystems/sysfs.txt  | 6 +++---
 drivers/base/core.c | 2 +-
 drivers/gpu/drm/msm/disp/dpu1/dpu_kms.h | 2 +-
 fs/Kconfig  | 2 +-
 fs/Kconfig.binfmt   | 2 +-
 fs/adfs/Kconfig | 2 +-
 fs/affs/Kconfig | 2 +-
 fs/afs/Kconfig  | 6 +++---
 fs/bfs/Kconfig  | 2 +-
 fs/cramfs/Kconfig   | 2 +-
 fs/ecryptfs/Kconfig | 2 +-
 fs/hfs/Kconfig  | 2 +-
 fs/hpfs/Kconfig | 2 +-
 fs/isofs/Kconfig| 2 +-
 fs/namespace.c  | 2 +-
 fs/notify/inotify/Kconfig   | 2 +-
 fs/ntfs/Kconfig | 2 +-
 fs/ocfs2/Kconfig| 2 +-
 fs/proc/Kconfig | 4 ++--
 fs/romfs/Kconfig| 2 +-
 fs/sysfs/dir.c  | 2 +-
 fs/sysfs/file.c | 2 +-
 fs/sysfs/mount.c| 2 +-
 fs/sysfs/symlink.c  | 2 +-
 fs/sysv/Kconfig | 2 +-
 fs/udf/Kconfig  | 2 +-
 include/linux/kobject.h | 2 +-
 include/linux/kobject_ns.h  | 2 +-
 include/linux/relay.h   | 2 +-
 include/linux/sysfs.h   | 2 +-
 kernel/relay.c  | 2 +-
 lib/kobject.c   | 4 ++--
 45 files changed, 52 insertions(+), 52 deletions(-)

diff --git a/Documentation/ABI/stable/sysfs-devices-node 
b/Documentation/ABI/stable/sysfs-devices-node
index df8413cf1468..484fc04bcc25 100644
--- a/Documentation/ABI/stable/sysfs-devices-node
+++ b/Documentation/ABI/stable/sysfs-devices-node
@@ -54,7 +54,7 @@ Date: October 2002
 Contact:   Linux Memory Management list 
 Description:
Provides information about the node's distribution and memory
-   utilization. Similar to /proc/meminfo, see 
Documentation/filesystems/proc.txt
+   utilization. Similar to /proc/meminfo, see 
Documentation/filesystems/proc.rst
 
 What:  /sys/devices/system/node/nodeX/numastat
 Date:  October 2002
diff --git a/Documentation/ABI/testing/procfs-smaps_rollup 
b/Documentation/ABI/testing/procfs-smaps_rollup
index 274df44d8b1b..046978193368 100644
--- a/Documentation/ABI/testing/procfs-smaps_rollup
+++ b/Documentation/ABI/testing/procfs-smaps_rollup
@@ -11,7 +11,7 @@ Description:
Additionally, the fields Pss_Anon, Pss_File and Pss_Shmem
are not present in /proc/pid/smaps.  These fields represent
the sum of the Pss field of each type (anon, file, shmem).
-   For more details, see Documentation/filesystems/proc.txt
+   For more details, see Documentation/filesystems/proc.rst
and the procfs man page.
 
Typical output looks like this:
diff --git a/Documentation/admin-guide/cpu-load.rst 
b/Documentation/admin-guide/cpu-load.rst
index 2d01ce43d2a2..ebdecf864080 100644
--- a/Documentation/admin-guide/cpu-load.rst
+++ b/Documentation/admin-guide/cpu-load.rst
@@ -105,7 +105,7

[PATCH v2 25/33] docs: powerpc: cxl.rst: mark two section titles as such

2020-04-14 Thread Mauro Carvalho Chehab
The User API chapter contains two sub-chapters. Mark them as
such.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/powerpc/cxl.rst | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/Documentation/powerpc/cxl.rst b/Documentation/powerpc/cxl.rst
index 920546d81326..d2d77057610e 100644
--- a/Documentation/powerpc/cxl.rst
+++ b/Documentation/powerpc/cxl.rst
@@ -133,6 +133,7 @@ User API
 
 
 1. AFU character devices
+
 
 For AFUs operating in AFU directed mode, two character device
 files will be created. /dev/cxl/afu0.0m will correspond to a
@@ -395,6 +396,7 @@ read
 
 
 2. Card character device (powerVM guest only)
+^
 
 In a powerVM guest, an extra character device is created for the
 card. The device is only used to write (flash) a new image on the
-- 
2.25.2



[PATCH v2 00/33] Documentation fixes for Kernel 5.8

2020-04-14 Thread Mauro Carvalho Chehab
Patches 1 to 5 contain changes to the documentation toolset:

- The first 3 patches help to reduce a lot the number of reported
  kernel-doc issues, by making the tool more smart.

- Patches 4 and 5 are meant to partially address the PDF
  build, with now requires Sphinx version 2.4 or upper.

The remaining patches fix broken references detected by
this tool:

./scripts/documentation-file-ref-check

and address other random errors due to tags being mis-interpreted
or mis-used.

They are independent each other, but some may depend on
the kernel-doc improvements.

PS.: Due to the large number of C/C, I opted to keep a smaller
set of C/C at this first e-mail (only e-mails with "L:" tag from
MAINTAINERS file).

Jon,

Those patches should apply cleanly at docs-next, once you
pull from v5.7-rc1.


-

v2:

- patches re-ordered;
- added reviewed/acked-by tags;
- rebased on the top of docs-next + v5.7-rc1.


Mauro Carvalho Chehab (33):
  scripts: kernel-doc: proper handle @foo->bar()
  scripts: kernel-doc: accept negation like !@var
  scripts: kernel-doc: accept blank lines on parameter description
  docs: update recommended Sphinx version to 2.4.4
  docs: LaTeX/PDF: drop list of documents
  MAINTAINERS: dt: update display/allwinner file entry
  MAINTAINERS: dt: fix pointers for ARM Integrator, Versatile and
RealView
  docs: dt: fix broken reference to phy-cadence-torrent.yaml
  docs: fix broken references to text files
  docs: fix broken references for ReST files that moved around
  docs: filesystems: fix renamed references
  docs: amu: supress some Sphinx warnings
  docs: arm64: booting.rst: get rid of some warnings
  docs: pci: boot-interrupts.rst: improve html output
  docs: ras: get rid of some warnings
  docs: ras: don't need to repeat twice the same thing
  docs: infiniband: verbs.c: fix some documentation warnings
  docs: spi: spi.h: fix a doc building warning
  docs: drivers: fix some warnings at base/platform.c when building docs
  docs: mm: userfaultfd.rst: use ``foo`` for literals
  docs: mm: userfaultfd.rst: use a cross-reference for a section
  docs: vm: index.rst: add an orphan doc to the building system
  docs: dt: qcom,dwc3.txt: fix cross-reference for a converted file
  docs: dt: fix a broken reference for a file converted to json
  docs: powerpc: cxl.rst: mark two section titles as such
  docs: i2c: rename i2c.svg to i2c_bus.svg
  docs: Makefile: place final pdf docs on a separate dir
  docs: dt: rockchip,dwc3.txt: fix a pointer to a renamed file
  ata: libata-core: fix a doc warning
  firewire: firewire-cdev.hL get rid of a docs warning
  fs: inode.c: get rid of docs warnings
  futex: get rid of a kernel-docs build warning
  lib: bitmap.c: get rid of some doc warnings

 Documentation/ABI/stable/sysfs-devices-node   |   2 +-
 Documentation/ABI/testing/procfs-smaps_rollup |   2 +-
 Documentation/Makefile|   6 +-
 Documentation/PCI/boot-interrupts.rst |  34 +--
 Documentation/admin-guide/cpu-load.rst|   2 +-
 Documentation/admin-guide/mm/userfaultfd.rst  | 209 +-
 Documentation/admin-guide/nfs/nfsroot.rst |   2 +-
 Documentation/admin-guide/ras.rst |  18 +-
 Documentation/arm64/amu.rst   |   5 +
 Documentation/arm64/booting.rst   |  36 +--
 Documentation/conf.py |  38 
 .../bindings/net/qualcomm-bluetooth.txt   |   2 +-
 .../bindings/phy/ti,phy-j721e-wiz.yaml|   2 +-
 .../devicetree/bindings/usb/qcom,dwc3.txt |   4 +-
 .../devicetree/bindings/usb/rockchip,dwc3.txt |   2 +-
 .../doc-guide/maintainer-profile.rst  |   2 +-
 .../driver-api/driver-model/device.rst|   4 +-
 .../driver-api/driver-model/overview.rst  |   2 +-
 Documentation/filesystems/dax.txt |   2 +-
 Documentation/filesystems/dnotify.txt |   2 +-
 .../filesystems/ramfs-rootfs-initramfs.rst|   2 +-
 Documentation/filesystems/sysfs.rst   |   2 +-
 Documentation/i2c/{i2c.svg => i2c_bus.svg}|   2 +-
 Documentation/i2c/summary.rst |   2 +-
 Documentation/memory-barriers.txt |   2 +-
 Documentation/powerpc/cxl.rst |   2 +
 .../powerpc/firmware-assisted-dump.rst|   2 +-
 Documentation/process/adding-syscalls.rst |   2 +-
 Documentation/process/submit-checklist.rst|   2 +-
 Documentation/sphinx/requirements.txt |   2 +-
 .../it_IT/process/adding-syscalls.rst |   2 +-
 .../it_IT/process/submit-checklist.rst|   2 +-
 .../translations/ko_KR/memory-barriers.txt|   2 +-
 .../translations/zh_CN/filesystems/sysfs.txt  |   8 +-
 .../zh_CN/process/submit-checklist.rst|   2 +-
 Documentation/virt/kvm/arm/pvtime.rst |   2 +-
 Documentation/virt/kvm/devices/vcpu.rst   |   2 +-
 Documentation/virt/kvm/hypercalls.rst |   4 +-
 Documentation/virt/kvm/mmu.rst|   2 +-
 Documentation/virt/kvm/review-check

[PATCH v2 09/33] docs: fix broken references to text files

2020-04-14 Thread Mauro Carvalho Chehab
Several references got broken due to txt to ReST conversion.

Several of them can be automatically fixed with:

scripts/documentation-file-ref-check --fix

Reviewed-by: Mathieu Poirier  # 
hwtracing/coresight/Kconfig
Reviewed-by: Paul E. McKenney  # memory-barrier.txt
Acked-by: Alex Shi  # translations/zh_CN
Acked-by: Federico Vaga  # translations/it_IT
Acked-by: Marc Zyngier  # kvm/arm64
Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/memory-barriers.txt|  2 +-
 Documentation/process/submit-checklist.rst   |  2 +-
 .../translations/it_IT/process/submit-checklist.rst  |  2 +-
 Documentation/translations/ko_KR/memory-barriers.txt |  2 +-
 .../translations/zh_CN/filesystems/sysfs.txt |  2 +-
 .../translations/zh_CN/process/submit-checklist.rst  |  2 +-
 Documentation/virt/kvm/arm/pvtime.rst|  2 +-
 Documentation/virt/kvm/devices/vcpu.rst  |  2 +-
 Documentation/virt/kvm/hypercalls.rst|  4 ++--
 arch/powerpc/include/uapi/asm/kvm_para.h |  2 +-
 drivers/gpu/drm/Kconfig  |  2 +-
 drivers/gpu/drm/drm_ioctl.c  |  2 +-
 drivers/hwtracing/coresight/Kconfig  |  2 +-
 fs/fat/Kconfig   |  8 
 fs/fuse/Kconfig  |  2 +-
 fs/fuse/dev.c|  2 +-
 fs/overlayfs/Kconfig |  6 +++---
 include/linux/mm.h   |  4 ++--
 include/uapi/linux/ethtool_netlink.h |  2 +-
 include/uapi/rdma/rdma_user_ioctl_cmds.h |  2 +-
 mm/gup.c | 12 ++--
 virt/kvm/arm/vgic/vgic-mmio-v3.c |  2 +-
 virt/kvm/arm/vgic/vgic.h |  4 ++--
 23 files changed, 36 insertions(+), 36 deletions(-)

diff --git a/Documentation/memory-barriers.txt 
b/Documentation/memory-barriers.txt
index e1c355e84edd..eaabc3134294 100644
--- a/Documentation/memory-barriers.txt
+++ b/Documentation/memory-barriers.txt
@@ -620,7 +620,7 @@ because the CPUs that the Linux kernel supports don't do 
writes
 until they are certain (1) that the write will actually happen, (2)
 of the location of the write, and (3) of the value to be written.
 But please carefully read the "CONTROL DEPENDENCIES" section and the
-Documentation/RCU/rcu_dereference.txt file:  The compiler can and does
+Documentation/RCU/rcu_dereference.rst file:  The compiler can and does
 break dependencies in a great many highly creative ways.
 
CPU 1 CPU 2
diff --git a/Documentation/process/submit-checklist.rst 
b/Documentation/process/submit-checklist.rst
index 8e56337d422d..3f8e9d5d95c2 100644
--- a/Documentation/process/submit-checklist.rst
+++ b/Documentation/process/submit-checklist.rst
@@ -107,7 +107,7 @@ and elsewhere regarding submitting Linux kernel patches.
 and why.
 
 26) If any ioctl's are added by the patch, then also update
-``Documentation/ioctl/ioctl-number.rst``.
+``Documentation/userspace-api/ioctl/ioctl-number.rst``.
 
 27) If your modified source code depends on or uses any of the kernel
 APIs or features that are related to the following ``Kconfig`` symbols,
diff --git a/Documentation/translations/it_IT/process/submit-checklist.rst 
b/Documentation/translations/it_IT/process/submit-checklist.rst
index 995ee69fab11..3e575502690f 100644
--- a/Documentation/translations/it_IT/process/submit-checklist.rst
+++ b/Documentation/translations/it_IT/process/submit-checklist.rst
@@ -117,7 +117,7 @@ sottomissione delle patch, in particolare
 sorgenti che ne spieghi la logica: cosa fanno e perché.
 
 25) Se la patch aggiunge nuove chiamate ioctl, allora aggiornate
-``Documentation/ioctl/ioctl-number.rst``.
+``Documentation/userspace-api/ioctl/ioctl-number.rst``.
 
 26) Se il codice che avete modificato dipende o usa una qualsiasi interfaccia o
 funzionalità del kernel che è associata a uno dei seguenti simboli
diff --git a/Documentation/translations/ko_KR/memory-barriers.txt 
b/Documentation/translations/ko_KR/memory-barriers.txt
index 2e831ece6e26..e50fe6541335 100644
--- a/Documentation/translations/ko_KR/memory-barriers.txt
+++ b/Documentation/translations/ko_KR/memory-barriers.txt
@@ -641,7 +641,7 @@ P 는 짝수 번호 캐시 라인에 저장되어 있고, 변수 B 는 홀수 
 리눅스 커널이 지원하는 CPU 들은 (1) 쓰기가 정말로 일어날지, (2) 쓰기가 어디에
 이루어질지, 그리고 (3) 쓰여질 값을 확실히 알기 전까지는 쓰기를 수행하지 않기
 때문입니다.  하지만 "컨트롤 의존성" 섹션과
-Documentation/RCU/rcu_dereference.txt 파일을 주의 깊게 읽어 주시기 바랍니다:
+Documentation/RCU/rcu_dereference.rst 파일을 주의 깊게 읽어 주시기 바랍니다:
 컴파일러는 매우 창의적인 많은 방법으로 종속성을 깰 수 있습니다.
 
CPU 1 CPU 2
diff --git a/Documentation/translations/zh_CN/filesystems/sysfs.txt 
b/Documentation/translations/zh_CN/filesystems/sysfs.txt
index ee1f37da5b23..a15c3ebdfa82 100644
--- a/Documentation/translations/zh_CN/f

Re: [PATCH 31/35] powerpc: docs: cxl.rst: mark two section titles as such

2020-04-08 Thread Mauro Carvalho Chehab
Em Thu, 9 Apr 2020 10:37:52 +1000
Andrew Donnellan  escreveu:

> On 9/4/20 1:46 am, Mauro Carvalho Chehab wrote:
> > The User API chapter contains two sub-chapters. Mark them as
> > such.
> > 
> > Signed-off-by: Mauro Carvalho Chehab   
> 
> Thanks.
> 
> Though the other subsections in this file use - rather than ^, 
> what's the difference?

ReST syntax allows the usage of several different markup symbols for
titles. It dynamically attributes the first one it finds as level 1,
the second one as level 2 and so on.

As we added the "" markup before "-", after this patch, it now has:

===
level 1
===

level 2
===

level 3
^^^

level 4
---


> 
> Acked-by: Andrew Donnellan 
> 
> > ---
> >   Documentation/powerpc/cxl.rst | 2 ++
> >   1 file changed, 2 insertions(+)
> > 
> > diff --git a/Documentation/powerpc/cxl.rst b/Documentation/powerpc/cxl.rst
> > index 920546d81326..d2d77057610e 100644
> > --- a/Documentation/powerpc/cxl.rst
> > +++ b/Documentation/powerpc/cxl.rst
> > @@ -133,6 +133,7 @@ User API
> >   
> >   
> >   1. AFU character devices
> > +
> >   
> >   For AFUs operating in AFU directed mode, two character device
> >   files will be created. /dev/cxl/afu0.0m will correspond to a
> > @@ -395,6 +396,7 @@ read
> >   
> >   
> >   2. Card character device (powerVM guest only)
> > +^
> >   
> >   In a powerVM guest, an extra character device is created for the
> >   card. The device is only used to write (flash) a new image on the
> >   
> 



Thanks,
Mauro


[PATCH 05/35] docs: filesystems: fix renamed references

2020-04-08 Thread Mauro Carvalho Chehab
Some filesystem references got broken by a previous patch
series I submitted. Address those.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/ABI/stable/sysfs-devices-node | 2 +-
 Documentation/ABI/testing/procfs-smaps_rollup   | 2 +-
 Documentation/admin-guide/cpu-load.rst  | 2 +-
 Documentation/admin-guide/nfs/nfsroot.rst   | 2 +-
 Documentation/driver-api/driver-model/device.rst| 4 ++--
 Documentation/driver-api/driver-model/overview.rst  | 2 +-
 Documentation/filesystems/dax.txt   | 2 +-
 Documentation/filesystems/dnotify.txt   | 2 +-
 Documentation/filesystems/ramfs-rootfs-initramfs.rst| 2 +-
 Documentation/filesystems/sysfs.rst | 2 +-
 Documentation/powerpc/firmware-assisted-dump.rst| 2 +-
 Documentation/process/adding-syscalls.rst   | 2 +-
 .../translations/it_IT/process/adding-syscalls.rst  | 2 +-
 Documentation/translations/zh_CN/filesystems/sysfs.txt  | 6 +++---
 drivers/base/core.c | 2 +-
 drivers/gpu/drm/msm/disp/dpu1/dpu_kms.h | 2 +-
 fs/Kconfig  | 2 +-
 fs/Kconfig.binfmt   | 2 +-
 fs/adfs/Kconfig | 2 +-
 fs/affs/Kconfig | 2 +-
 fs/afs/Kconfig  | 6 +++---
 fs/bfs/Kconfig  | 2 +-
 fs/cramfs/Kconfig   | 2 +-
 fs/ecryptfs/Kconfig | 2 +-
 fs/hfs/Kconfig  | 2 +-
 fs/hpfs/Kconfig | 2 +-
 fs/isofs/Kconfig| 2 +-
 fs/namespace.c  | 2 +-
 fs/notify/inotify/Kconfig   | 2 +-
 fs/ntfs/Kconfig | 2 +-
 fs/ocfs2/Kconfig| 2 +-
 fs/proc/Kconfig | 4 ++--
 fs/romfs/Kconfig| 2 +-
 fs/sysfs/dir.c  | 2 +-
 fs/sysfs/file.c | 2 +-
 fs/sysfs/mount.c| 2 +-
 fs/sysfs/symlink.c  | 2 +-
 fs/sysv/Kconfig | 2 +-
 fs/udf/Kconfig  | 2 +-
 include/linux/kobject.h | 2 +-
 include/linux/kobject_ns.h  | 2 +-
 include/linux/relay.h   | 2 +-
 include/linux/sysfs.h   | 2 +-
 kernel/relay.c  | 2 +-
 lib/kobject.c   | 4 ++--
 45 files changed, 52 insertions(+), 52 deletions(-)

diff --git a/Documentation/ABI/stable/sysfs-devices-node 
b/Documentation/ABI/stable/sysfs-devices-node
index df8413cf1468..484fc04bcc25 100644
--- a/Documentation/ABI/stable/sysfs-devices-node
+++ b/Documentation/ABI/stable/sysfs-devices-node
@@ -54,7 +54,7 @@ Date: October 2002
 Contact:   Linux Memory Management list 
 Description:
Provides information about the node's distribution and memory
-   utilization. Similar to /proc/meminfo, see 
Documentation/filesystems/proc.txt
+   utilization. Similar to /proc/meminfo, see 
Documentation/filesystems/proc.rst
 
 What:  /sys/devices/system/node/nodeX/numastat
 Date:  October 2002
diff --git a/Documentation/ABI/testing/procfs-smaps_rollup 
b/Documentation/ABI/testing/procfs-smaps_rollup
index 274df44d8b1b..046978193368 100644
--- a/Documentation/ABI/testing/procfs-smaps_rollup
+++ b/Documentation/ABI/testing/procfs-smaps_rollup
@@ -11,7 +11,7 @@ Description:
Additionally, the fields Pss_Anon, Pss_File and Pss_Shmem
are not present in /proc/pid/smaps.  These fields represent
the sum of the Pss field of each type (anon, file, shmem).
-   For more details, see Documentation/filesystems/proc.txt
+   For more details, see Documentation/filesystems/proc.rst
and the procfs man page.
 
Typical output looks like this:
diff --git a/Documentation/admin-guide/cpu-load.rst 
b/Documentation/admin-guide/cpu-load.rst
index 2d01ce43d2a2..ebdecf864080 100644
--- a/Documentation/admin-guide/cpu-load.rst
+++ b/Documentation/admin-guide/cpu-load.rst
@@ -105,7 +105,7 @@ References
 --
 
 - http

[PATCH 03/35] docs: fix broken references to text files

2020-04-08 Thread Mauro Carvalho Chehab
Several references got broken due to txt to ReST conversion.

Several of them can be automatically fixed with:

scripts/documentation-file-ref-check --fix

Reviewed-by: Mathieu Poirier  # 
hwtracing/coresight/Kconfig
Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/memory-barriers.txt|  2 +-
 Documentation/process/submit-checklist.rst   |  2 +-
 .../translations/it_IT/process/submit-checklist.rst  |  2 +-
 Documentation/translations/ko_KR/memory-barriers.txt |  2 +-
 .../translations/zh_CN/filesystems/sysfs.txt |  2 +-
 .../translations/zh_CN/process/submit-checklist.rst  |  2 +-
 Documentation/virt/kvm/arm/pvtime.rst|  2 +-
 Documentation/virt/kvm/devices/vcpu.rst  |  2 +-
 Documentation/virt/kvm/hypercalls.rst|  4 ++--
 arch/powerpc/include/uapi/asm/kvm_para.h |  2 +-
 drivers/gpu/drm/Kconfig  |  2 +-
 drivers/gpu/drm/drm_ioctl.c  |  2 +-
 drivers/hwtracing/coresight/Kconfig  |  2 +-
 fs/fat/Kconfig   |  8 
 fs/fuse/Kconfig  |  2 +-
 fs/fuse/dev.c|  2 +-
 fs/overlayfs/Kconfig |  6 +++---
 include/linux/mm.h   |  4 ++--
 include/uapi/linux/ethtool_netlink.h |  2 +-
 include/uapi/rdma/rdma_user_ioctl_cmds.h |  2 +-
 mm/gup.c | 12 ++--
 virt/kvm/arm/vgic/vgic-mmio-v3.c |  2 +-
 virt/kvm/arm/vgic/vgic.h |  4 ++--
 23 files changed, 36 insertions(+), 36 deletions(-)

diff --git a/Documentation/memory-barriers.txt 
b/Documentation/memory-barriers.txt
index e1c355e84edd..eaabc3134294 100644
--- a/Documentation/memory-barriers.txt
+++ b/Documentation/memory-barriers.txt
@@ -620,7 +620,7 @@ because the CPUs that the Linux kernel supports don't do 
writes
 until they are certain (1) that the write will actually happen, (2)
 of the location of the write, and (3) of the value to be written.
 But please carefully read the "CONTROL DEPENDENCIES" section and the
-Documentation/RCU/rcu_dereference.txt file:  The compiler can and does
+Documentation/RCU/rcu_dereference.rst file:  The compiler can and does
 break dependencies in a great many highly creative ways.
 
CPU 1 CPU 2
diff --git a/Documentation/process/submit-checklist.rst 
b/Documentation/process/submit-checklist.rst
index 8e56337d422d..3f8e9d5d95c2 100644
--- a/Documentation/process/submit-checklist.rst
+++ b/Documentation/process/submit-checklist.rst
@@ -107,7 +107,7 @@ and elsewhere regarding submitting Linux kernel patches.
 and why.
 
 26) If any ioctl's are added by the patch, then also update
-``Documentation/ioctl/ioctl-number.rst``.
+``Documentation/userspace-api/ioctl/ioctl-number.rst``.
 
 27) If your modified source code depends on or uses any of the kernel
 APIs or features that are related to the following ``Kconfig`` symbols,
diff --git a/Documentation/translations/it_IT/process/submit-checklist.rst 
b/Documentation/translations/it_IT/process/submit-checklist.rst
index 995ee69fab11..3e575502690f 100644
--- a/Documentation/translations/it_IT/process/submit-checklist.rst
+++ b/Documentation/translations/it_IT/process/submit-checklist.rst
@@ -117,7 +117,7 @@ sottomissione delle patch, in particolare
 sorgenti che ne spieghi la logica: cosa fanno e perché.
 
 25) Se la patch aggiunge nuove chiamate ioctl, allora aggiornate
-``Documentation/ioctl/ioctl-number.rst``.
+``Documentation/userspace-api/ioctl/ioctl-number.rst``.
 
 26) Se il codice che avete modificato dipende o usa una qualsiasi interfaccia o
 funzionalità del kernel che è associata a uno dei seguenti simboli
diff --git a/Documentation/translations/ko_KR/memory-barriers.txt 
b/Documentation/translations/ko_KR/memory-barriers.txt
index 2e831ece6e26..e50fe6541335 100644
--- a/Documentation/translations/ko_KR/memory-barriers.txt
+++ b/Documentation/translations/ko_KR/memory-barriers.txt
@@ -641,7 +641,7 @@ P 는 짝수 번호 캐시 라인에 저장되어 있고, 변수 B 는 홀수 
 리눅스 커널이 지원하는 CPU 들은 (1) 쓰기가 정말로 일어날지, (2) 쓰기가 어디에
 이루어질지, 그리고 (3) 쓰여질 값을 확실히 알기 전까지는 쓰기를 수행하지 않기
 때문입니다.  하지만 "컨트롤 의존성" 섹션과
-Documentation/RCU/rcu_dereference.txt 파일을 주의 깊게 읽어 주시기 바랍니다:
+Documentation/RCU/rcu_dereference.rst 파일을 주의 깊게 읽어 주시기 바랍니다:
 컴파일러는 매우 창의적인 많은 방법으로 종속성을 깰 수 있습니다.
 
CPU 1 CPU 2
diff --git a/Documentation/translations/zh_CN/filesystems/sysfs.txt 
b/Documentation/translations/zh_CN/filesystems/sysfs.txt
index ee1f37da5b23..a15c3ebdfa82 100644
--- a/Documentation/translations/zh_CN/filesystems/sysfs.txt
+++ b/Documentation/translations/zh_CN/filesystems/sysfs.txt
@@ -281,7 +281,7 @@ drivers/ 包含了每个已为特定总线上的设备而挂载的驱动程序
 假定驱动没有跨越多个总线类型)。
 
 fs/ 包含了一个为文件系统设立的目录。现在每

[PATCH 31/35] powerpc: docs: cxl.rst: mark two section titles as such

2020-04-08 Thread Mauro Carvalho Chehab
The User API chapter contains two sub-chapters. Mark them as
such.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/powerpc/cxl.rst | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/Documentation/powerpc/cxl.rst b/Documentation/powerpc/cxl.rst
index 920546d81326..d2d77057610e 100644
--- a/Documentation/powerpc/cxl.rst
+++ b/Documentation/powerpc/cxl.rst
@@ -133,6 +133,7 @@ User API
 
 
 1. AFU character devices
+
 
 For AFUs operating in AFU directed mode, two character device
 files will be created. /dev/cxl/afu0.0m will correspond to a
@@ -395,6 +396,7 @@ read
 
 
 2. Card character device (powerVM guest only)
+^
 
 In a powerVM guest, an extra character device is created for the
 card. The device is only used to write (flash) a new image on the
-- 
2.25.2



[PATCH 00/35] Documentation fixes for Kernel 5.8

2020-04-08 Thread Mauro Carvalho Chehab
Hi Jon,

I have a large list of patches this time for the Documentation/. So, I'm
starting sending them a little earier. Yet, those are meant to be applied
after the end of the merge window. They're based on today's linux-next,
with has only 49 patches pending to be applied upstream touching
Documentation/, so I don't expect much conflicts if applied early at
-rc cycle.

Most of the patches here were already submitted, but weren't
merged yet at next. So, it seems that nobody picked them yet.

In any case, most of those patches here are independent from 
the others.

The number of doc build warnings have been rising with time.
The main goal with this series is to get rid of most Sphinx warnings
and other errors.

Patches 1 to 5: fix broken references detected by this tool:

./scripts/documentation-file-ref-check

The other patches fix other random errors due to tags being
mis-interpreted or mis-used.

You should notice that several patches touch kernel-doc scripts.
IMHO, some of the warnings are actually due to kernel-doc being
too pedantic. So, I ended by improving some things at the toolset,
in order to make it smarter. That's the case of those patches:

docs: scripts/kernel-doc: accept blank lines on parameter description
scripts: kernel-doc: accept negation like !@var
scripts: kernel-doc: proper handle @foo->bar()

The last 4 patches address problems with PDF building.

The first one address a conflict that will rise during the merge
window: Documentation/media will be removed. Instead of
just drop it from the list of PDF documents, I opted to drop the
entire list, as conf.py will auto-generate from the sources:

docs: LaTeX/PDF: drop list of documents

Also, right now, PDF output is broken due to a namespace conflict 
at I2c (two pdf outputs there will have the same name).

docs: i2c: rename i2c.svg to i2c_bus.svg

The third PDF patch is not really a fix, but it helps a lot to identify
if the build succeeded or not, by placing the final PDF output on
a separate dir:

docs: Makefile: place final pdf docs on a separate dir

Finally, the last one solves a bug since the first supported Sphinx
version, with also impacts PDF output: basically while nested tables
are valid with ReST notation, the toolset only started supporting
it on PDF output since version 2.4:

docs: update recommended Sphinx version to 2.4.4

PS.: Due to the large number of C/C, I opted to keep a smaller
set of C/C at this first e-mail (only e-mails with "L:" tag from
MAINTAINERS file).

Mauro Carvalho Chehab (35):
  MAINTAINERS: dt: update display/allwinner file entry
  docs: dt: fix broken reference to phy-cadence-torrent.yaml
  docs: fix broken references to text files
  docs: fix broken references for ReST files that moved around
  docs: filesystems: fix renamed references
  docs: amu: supress some Sphinx warnings
  docs: arm64: booting.rst: get rid of some warnings
  docs: pci: boot-interrupts.rst: improve html output
  futex: get rid of a kernel-docs build warning
  firewire: firewire-cdev.hL get rid of a docs warning
  scripts: kernel-doc: proper handle @foo->bar()
  lib: bitmap.c: get rid of some doc warnings
  ata: libata-core: fix a doc warning
  fs: inode.c: get rid of docs warnings
  docs: ras: get rid of some warnings
  docs: ras: don't need to repeat twice the same thing
  docs: watch_queue.rst: supress some Sphinx warnings
  scripts: kernel-doc: accept negation like !@var
  docs: infiniband: verbs.c: fix some documentation warnings
  docs: scripts/kernel-doc: accept blank lines on parameter description
  docs: spi: spi.h: fix a doc building warning
  docs: drivers: fix some warnings at base/platform.c when building docs
  docs: fusion: mptbase.c: get rid of a doc build warning
  docs: mm: slab.h: fix a broken cross-reference
  docs mm: userfaultfd.rst: use ``foo`` for literals
  docs: mm: userfaultfd.rst: use a cross-reference for a section
  docs: vm: index.rst: add an orphan doc to the building system
  docs: dt: qcom,dwc3.txt: fix cross-reference for a converted file
  MAINTAINERS: dt: fix pointers for ARM Integrator, Versatile and
RealView
  docs: dt: fix a broken reference for a file converted to json
  powerpc: docs: cxl.rst: mark two section titles as such
  docs: LaTeX/PDF: drop list of documents
  docs: i2c: rename i2c.svg to i2c_bus.svg
  docs: Makefile: place final pdf docs on a separate dir
  docs: update recommended Sphinx version to 2.4.4

 Documentation/ABI/stable/sysfs-devices-node   |   2 +-
 Documentation/ABI/testing/procfs-smaps_rollup |   2 +-
 Documentation/Makefile|   6 +-
 Documentation/PCI/boot-interrupts.rst |  34 +--
 Documentation/admin-guide/cpu-load.rst|   2 +-
 Documentation/admin-guide/mm/userfaultfd.rst  | 209 +-
 Documentation/admin-guide/nfs/nfsroot.rst |   2 +-
 Documentation/admin-guide/ras.rst |  18 +-
 Documentati

Re: [PATCH v2 0/2] Don't generate thousands of new warnings when building docs

2020-04-08 Thread Mauro Carvalho Chehab
Em Tue, 07 Apr 2020 13:46:23 +1000
Michael Ellerman  escreveu:

> Mauro Carvalho Chehab  writes:
> > This small series address a regression caused by a new patch at
> > docs-next (and at linux-next).
> >

...

> > This solves almost all problems we have. Still, there are a few places
> > where we have two chapters at the same document with the
> > same name. The first patch addresses this problem.  
> 
> I'm still seeing a lot of warnings. Am I doing something wrong?
> 
> cheers
> 
> /linux/Documentation/powerpc/cxl.rst:406: WARNING: duplicate label 
> powerpc/cxl:open, other instance in /linux/Documentation/powerpc/cxl.rst
...
> /linux/Documentation/powerpc/syscall64-abi.rst:86: WARNING: duplicate label 
> powerpc/syscall64-abi:parameters and return value, other instance in 
> /linux/Documentation/powerpc/syscall64-abi.rst
...
> /linux/Documentation/powerpc/ultravisor.rst:339: WARNING: duplicate label 
> powerpc/ultravisor:syntax, other instance in 
> /linux/Documentation/powerpc/ultravisor.rst
...

I can't reproduce your issue here at linux-next (+ my pending doc patches).

So, I can only provide you some hints.

If you see the logs you posted, all of them are related to duplicated
labels inside the same file.

-

The new Sphinx module we're using (sphinx.ext.autosectionlabel) generates
references for two levels, within the same document file (after this patch).


Looking at the first document (at linux-next version), it has:

1) A first level document title:

   Coherent Accelerator Interface (CXL)

2) Several second level titles:

   Introduction
   Hardware overview
   AFU Modes
   MMIO space
   Interrupts
   Work Element Descriptor (WED)
   User API
   Sysfs Class
   Udev rules

Right now, there's no duplication, but if someone adds, for example, 
another first-level or second-level title called "Interrupts", then 
the file will produce a duplicated label and Sphinx will warn.

The same would happen if someone adds another title (either first
level or second level) called "Coherent Accelerator Interface (CXL)",
as this will conflict with the document title.

-

Now, if the title "Coherent Accelerator Interface (CXL)" got removed,
then "Introduction".."Udev rules" will become first level titles.

Then, the sections at the "User API": "open", "ioctl"... will become
second level titles and it will produce lots of warnings.

-

That's said, IMHO, this document needs section titles for the two
sections under "User API". Adding it would allow removing the document
title. See enclosed.

Thanks,
Mauro

powerpc: docs: cxl.rst: mark two section titles as such

The User API chapter contains two sub-chapters. Mark them as
such.

Signed-off-by: Mauro Carvalho Chehab 


diff --git a/Documentation/powerpc/cxl.rst b/Documentation/powerpc/cxl.rst
index 920546d81326..d2d77057610e 100644
--- a/Documentation/powerpc/cxl.rst
+++ b/Documentation/powerpc/cxl.rst
@@ -133,6 +133,7 @@ User API
 
 
 1. AFU character devices
+
 
 For AFUs operating in AFU directed mode, two character device
 files will be created. /dev/cxl/afu0.0m will correspond to a
@@ -395,6 +396,7 @@ read
 
 
 2. Card character device (powerVM guest only)
+^
 
 In a powerVM guest, an extra character device is created for the
 card. The device is only used to write (flash) a new image on the



[PATCH v2 1/2] docs: prevent warnings due to autosectionlabel

2020-03-20 Thread Mauro Carvalho Chehab
Changeset 58ad30cf91f0 ("docs: fix reference to core-api/namespaces.rst")
enabled a new feature at Sphinx: it will now generate index for each
document title, plus to each chapter inside it.

There's a drawback, though: one document cannot have two sections
with the same name anymore.

A followup patch will change the logic of autosectionlabel to
avoid most creating references for every single section title,
but still we need to be able to reference the chapters inside
a document.

There are a few places where there are two chapters with the
same name. This patch renames one of the chapters, in order to
avoid symbol conflict within the same document.

PS.: as I don't speach Chinese, I had some help from a friend
(Wen Liu) at the Chinese translation for "publishing patches"
for this document:

Documentation/translations/zh_CN/process/5.Posting.rst

Fixes: 58ad30cf91f0 ("docs: fix reference to core-api/namespaces.rst")
Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/driver-api/80211/mac80211-advanced.rst  |  8 
 Documentation/driver-api/dmaengine/index.rst  |  4 ++--
 Documentation/filesystems/ecryptfs.rst| 11 +--
 Documentation/kernel-hacking/hacking.rst  |  4 ++--
 Documentation/media/kapi/v4l2-controls.rst|  8 
 Documentation/networking/snmp_counter.rst |  4 ++--
 Documentation/powerpc/ultravisor.rst  |  4 ++--
 Documentation/security/siphash.rst|  8 
 Documentation/target/tcmu-design.rst  |  6 +++---
 .../translations/zh_CN/process/5.Posting.rst  |  2 +-
 Documentation/x86/intel-iommu.rst |  3 ++-
 11 files changed, 31 insertions(+), 31 deletions(-)

diff --git a/Documentation/driver-api/80211/mac80211-advanced.rst 
b/Documentation/driver-api/80211/mac80211-advanced.rst
index 9f1c5bb7ac35..24cb64b3b715 100644
--- a/Documentation/driver-api/80211/mac80211-advanced.rst
+++ b/Documentation/driver-api/80211/mac80211-advanced.rst
@@ -272,8 +272,8 @@ STA information lifetime rules
 .. kernel-doc:: net/mac80211/sta_info.c
:doc: STA information lifetime rules
 
-Aggregation
-===
+Aggregation Functions
+=
 
 .. kernel-doc:: net/mac80211/sta_info.h
:functions: sta_ampdu_mlme
@@ -284,8 +284,8 @@ Aggregation
 .. kernel-doc:: net/mac80211/sta_info.h
:functions: tid_ampdu_rx
 
-Synchronisation
-===
+Synchronisation Functions
+=
 
 TBD
 
diff --git a/Documentation/driver-api/dmaengine/index.rst 
b/Documentation/driver-api/dmaengine/index.rst
index b9df904d0a79..bdc45d8b4cfb 100644
--- a/Documentation/driver-api/dmaengine/index.rst
+++ b/Documentation/driver-api/dmaengine/index.rst
@@ -5,8 +5,8 @@ DMAEngine documentation
 DMAEngine documentation provides documents for various aspects of DMAEngine
 framework.
 
-DMAEngine documentation

+DMAEngine development documentation
+---
 
 This book helps with DMAengine internal APIs and guide for DMAEngine device
 driver writers.
diff --git a/Documentation/filesystems/ecryptfs.rst 
b/Documentation/filesystems/ecryptfs.rst
index 7236172300ef..1f2edef4c57a 100644
--- a/Documentation/filesystems/ecryptfs.rst
+++ b/Documentation/filesystems/ecryptfs.rst
@@ -30,13 +30,12 @@ Userspace requirements include:
 - Libgcrypt
 
 
-Notes
-=
+.. note::
 
-In the beta/experimental releases of eCryptfs, when you upgrade
-eCryptfs, you should copy the files to an unencrypted location and
-then copy the files back into the new eCryptfs mount to migrate the
-files.
+   In the beta/experimental releases of eCryptfs, when you upgrade
+   eCryptfs, you should copy the files to an unencrypted location and
+   then copy the files back into the new eCryptfs mount to migrate the
+   files.
 
 
 Mount-wide Passphrase
diff --git a/Documentation/kernel-hacking/hacking.rst 
b/Documentation/kernel-hacking/hacking.rst
index d707a0a61cc9..eed2136d847f 100644
--- a/Documentation/kernel-hacking/hacking.rst
+++ b/Documentation/kernel-hacking/hacking.rst
@@ -601,7 +601,7 @@ Defined in ``include/linux/export.h``
 
 This is the variant of `EXPORT_SYMBOL()` that allows specifying a symbol
 namespace. Symbol Namespaces are documented in
-:ref:`Documentation/core-api/symbol-namespaces.rst `
+:doc:`../core-api/symbol-namespaces`
 
 :c:func:`EXPORT_SYMBOL_NS_GPL()`
 
@@ -610,7 +610,7 @@ Defined in ``include/linux/export.h``
 
 This is the variant of `EXPORT_SYMBOL_GPL()` that allows specifying a symbol
 namespace. Symbol Namespaces are documented in
-:ref:`Documentation/core-api/symbol-namespaces.rst `
+:doc:`../core-api/symbol-namespaces`
 
 Routines and Conventions
 
diff --git a/Documentation/media/kapi/v4l2-controls.rst 
b/Documentation/media/kapi/v4l2-controls.rst
index b20800cae3f2..5129019afb49 100644
--- a

[PATCH v2 0/2] Don't generate thousands of new warnings when building docs

2020-03-20 Thread Mauro Carvalho Chehab
This small series address a regression caused by a new patch at
docs-next (and at linux-next).

Before this patch, when a cross-reference to a chapter within the
documentation is needed, we had to add a markup like:

.. _foo:

foo
===

This behavor is now different after this patch:

58ad30cf91f0 ("docs: fix reference to core-api/namespaces.rst")

As a Sphinx extension now creates automatically a reference
like the above, without requiring any extra markup.

That, however, comes with a price: it is not possible anymore to have
two sections with the same name within the entire Kernel docs!

This causes thousands of warnings, as we have sections named
"introduction" on lots of places.

This series solve this regression by doing two changes:

1) The references are now prefixed by the document name. So,
   a file named "bar" would have the "foo" reference as "bar:foo".

2) It will only use the first two levels. The first one is (usually) the
   name of the document, and the second one the chapter name.

This solves almost all problems we have. Still, there are a few places
where we have two chapters at the same document with the
same name. The first patch addresses this problem.

The second patch limits the escope of the autosectionlabel.

Mauro Carvalho Chehab (2):
  docs: prevent warnings due to autosectionlabel
  docs: conf.py: avoid thousands of duplicate label warning on Sphinx

 Documentation/conf.py |  4 
 Documentation/driver-api/80211/mac80211-advanced.rst  |  8 
 Documentation/driver-api/dmaengine/index.rst  |  4 ++--
 Documentation/filesystems/ecryptfs.rst| 11 +--
 Documentation/kernel-hacking/hacking.rst  |  4 ++--
 Documentation/media/kapi/v4l2-controls.rst|  8 
 Documentation/networking/snmp_counter.rst |  4 ++--
 Documentation/powerpc/ultravisor.rst  |  4 ++--
 Documentation/security/siphash.rst|  8 
 Documentation/target/tcmu-design.rst  |  6 +++---
 .../translations/zh_CN/process/5.Posting.rst  |  2 +-
 Documentation/x86/intel-iommu.rst |  3 ++-
 12 files changed, 35 insertions(+), 31 deletions(-)

-- 
2.24.1




[PATCH 00/12] Fix broken references for Documentation/*

2020-03-18 Thread Mauro Carvalho Chehab
This patch series is against next-20200317. It fixes all references to files
under Documentation/* that were moved, renamed or removed.

After this patch series, this script:
./scripts/documentation-file-ref-check

Doesn't complain about any broken reference.

Mauro Carvalho Chehab (12):
  MAINTAINERS: dt: update display/allwinner file entry
  MAINTAINERS: dt: update etnaviv file reference
  MAINTAINERS: drop an old reference to stm32 pwm timers doc
  docs: dt: fix references to m_can.txt file
  docs: dt: fix references to ap806-system-controller.txt
  docs: dt: fix a broken reference to input.yaml
  docs: dt: fix broken reference to phy-cadence-torrent.yaml
  docs: fix broken references to text files
  docs: fix broken references for ReST files that moved around
  docs: dt: display/ti: fix typos at the devicetree/ directory name
  docs: filesystems: fix renamed references
  docs: kernel-parameters.txt: remove reference for removed Intel MPX

 Documentation/ABI/stable/sysfs-devices-node   |  2 +-
 Documentation/ABI/testing/procfs-smaps_rollup |  2 +-
 Documentation/admin-guide/cpu-load.rst|  2 +-
 .../admin-guide/kernel-parameters.txt | 11 ++--
 Documentation/admin-guide/nfs/nfsroot.rst |  2 +-
 .../bindings/arm/freescale/fsl,scu.txt|  2 +-
 .../bindings/display/ti/ti,am65x-dss.yaml |  2 +-
 .../bindings/display/ti/ti,j721e-dss.yaml |  2 +-
 .../bindings/display/ti/ti,k2g-dss.yaml   |  2 +-
 .../devicetree/bindings/gpio/gpio-mvebu.txt   |  2 +-
 .../devicetree/bindings/net/can/tcan4x5x.txt  |  2 +-
 .../bindings/phy/ti,phy-j721e-wiz.yaml|  2 +-
 .../bindings/thermal/armada-thermal.txt   |  2 +-
 .../doc-guide/maintainer-profile.rst  |  2 +-
 .../driver-api/driver-model/device.rst|  4 +-
 .../driver-api/driver-model/overview.rst  |  2 +-
 Documentation/filesystems/dax.txt |  2 +-
 Documentation/filesystems/dnotify.txt |  2 +-
 .../filesystems/ramfs-rootfs-initramfs.rst|  2 +-
 Documentation/filesystems/sysfs.rst   |  2 +-
 Documentation/memory-barriers.txt |  2 +-
 .../powerpc/firmware-assisted-dump.rst|  2 +-
 Documentation/process/adding-syscalls.rst |  2 +-
 Documentation/process/submit-checklist.rst|  2 +-
 .../it_IT/process/adding-syscalls.rst |  2 +-
 .../it_IT/process/submit-checklist.rst|  2 +-
 .../translations/ko_KR/memory-barriers.txt|  2 +-
 .../translations/zh_CN/filesystems/sysfs.txt  |  8 +--
 .../zh_CN/process/submit-checklist.rst|  2 +-
 Documentation/virt/kvm/arm/pvtime.rst |  2 +-
 Documentation/virt/kvm/devices/vcpu.rst   |  2 +-
 Documentation/virt/kvm/hypercalls.rst |  4 +-
 Documentation/virt/kvm/mmu.rst|  2 +-
 Documentation/virt/kvm/review-checklist.rst   |  2 +-
 MAINTAINERS   | 61 +--
 Next/merge.log| 12 ++--
 arch/powerpc/include/uapi/asm/kvm_para.h  |  2 +-
 arch/x86/kvm/mmu/mmu.c|  2 +-
 drivers/base/core.c   |  2 +-
 .../allwinner/sun8i-ce/sun8i-ce-cipher.c  |  2 +-
 .../crypto/allwinner/sun8i-ce/sun8i-ce-core.c |  2 +-
 .../allwinner/sun8i-ss/sun8i-ss-cipher.c  |  2 +-
 .../crypto/allwinner/sun8i-ss/sun8i-ss-core.c |  2 +-
 drivers/gpu/drm/Kconfig   |  2 +-
 drivers/gpu/drm/drm_ioctl.c   |  2 +-
 drivers/gpu/drm/msm/disp/dpu1/dpu_kms.h   |  2 +-
 drivers/hwtracing/coresight/Kconfig   |  2 +-
 drivers/media/v4l2-core/v4l2-fwnode.c |  2 +-
 fs/Kconfig|  2 +-
 fs/Kconfig.binfmt |  2 +-
 fs/adfs/Kconfig   |  2 +-
 fs/affs/Kconfig   |  2 +-
 fs/afs/Kconfig|  6 +-
 fs/bfs/Kconfig|  2 +-
 fs/cramfs/Kconfig |  2 +-
 fs/ecryptfs/Kconfig   |  2 +-
 fs/fat/Kconfig|  8 +--
 fs/fuse/Kconfig   |  2 +-
 fs/fuse/dev.c |  2 +-
 fs/hfs/Kconfig|  2 +-
 fs/hpfs/Kconfig   |  2 +-
 fs/isofs/Kconfig  |  2 +-
 fs/namespace.c|  2 +-
 fs/notify/inotify/Kconfig |  2 +-
 fs/ntfs/Kconfig   |  2 +-
 fs/ocfs2/Kconfig  |  2 +-
 fs/overlayfs/Kconfig  |  6 +-
 fs/proc/Kconfig   |  4 +-
 fs/romfs/Kconfig  |  2 +-
 fs/sysfs/dir.c|  2 +-
 fs/sysfs/file.c   |  2 +-
 fs/sysfs/mount.c  |  2 +-
 fs/sysfs/symlink.c

[PATCH 11/12] docs: filesystems: fix renamed references

2020-03-17 Thread Mauro Carvalho Chehab
Some filesystem references got broken by a previous patch
series I submitted. Address those.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/ABI/stable/sysfs-devices-node   |  2 +-
 Documentation/ABI/testing/procfs-smaps_rollup |  2 +-
 Documentation/admin-guide/cpu-load.rst|  2 +-
 .../admin-guide/kernel-parameters.txt |  2 +-
 Documentation/admin-guide/nfs/nfsroot.rst |  2 +-
 .../driver-api/driver-model/device.rst|  4 +-
 .../driver-api/driver-model/overview.rst  |  2 +-
 Documentation/filesystems/dax.txt |  2 +-
 Documentation/filesystems/dnotify.txt |  2 +-
 .../filesystems/ramfs-rootfs-initramfs.rst|  2 +-
 Documentation/filesystems/sysfs.rst   |  2 +-
 .../powerpc/firmware-assisted-dump.rst|  2 +-
 Documentation/process/adding-syscalls.rst |  2 +-
 .../it_IT/process/adding-syscalls.rst |  2 +-
 .../translations/zh_CN/filesystems/sysfs.txt  |  6 +--
 MAINTAINERS   | 54 +--
 Next/merge.log| 12 ++---
 drivers/base/core.c   |  2 +-
 drivers/gpu/drm/msm/disp/dpu1/dpu_kms.h   |  2 +-
 fs/Kconfig|  2 +-
 fs/Kconfig.binfmt |  2 +-
 fs/adfs/Kconfig   |  2 +-
 fs/affs/Kconfig   |  2 +-
 fs/afs/Kconfig|  6 +--
 fs/bfs/Kconfig|  2 +-
 fs/cramfs/Kconfig |  2 +-
 fs/ecryptfs/Kconfig   |  2 +-
 fs/hfs/Kconfig|  2 +-
 fs/hpfs/Kconfig   |  2 +-
 fs/isofs/Kconfig  |  2 +-
 fs/namespace.c|  2 +-
 fs/notify/inotify/Kconfig |  2 +-
 fs/ntfs/Kconfig   |  2 +-
 fs/ocfs2/Kconfig  |  2 +-
 fs/proc/Kconfig   |  4 +-
 fs/romfs/Kconfig  |  2 +-
 fs/sysfs/dir.c|  2 +-
 fs/sysfs/file.c   |  2 +-
 fs/sysfs/mount.c  |  2 +-
 fs/sysfs/symlink.c|  2 +-
 fs/sysv/Kconfig   |  2 +-
 fs/udf/Kconfig|  2 +-
 include/linux/kobject.h   |  2 +-
 include/linux/kobject_ns.h|  2 +-
 include/linux/relay.h |  2 +-
 include/linux/sysfs.h |  2 +-
 kernel/relay.c|  2 +-
 lib/kobject.c |  4 +-
 48 files changed, 86 insertions(+), 86 deletions(-)

diff --git a/Documentation/ABI/stable/sysfs-devices-node 
b/Documentation/ABI/stable/sysfs-devices-node
index df8413cf1468..484fc04bcc25 100644
--- a/Documentation/ABI/stable/sysfs-devices-node
+++ b/Documentation/ABI/stable/sysfs-devices-node
@@ -54,7 +54,7 @@ Date: October 2002
 Contact:   Linux Memory Management list 
 Description:
Provides information about the node's distribution and memory
-   utilization. Similar to /proc/meminfo, see 
Documentation/filesystems/proc.txt
+   utilization. Similar to /proc/meminfo, see 
Documentation/filesystems/proc.rst
 
 What:  /sys/devices/system/node/nodeX/numastat
 Date:  October 2002
diff --git a/Documentation/ABI/testing/procfs-smaps_rollup 
b/Documentation/ABI/testing/procfs-smaps_rollup
index 274df44d8b1b..046978193368 100644
--- a/Documentation/ABI/testing/procfs-smaps_rollup
+++ b/Documentation/ABI/testing/procfs-smaps_rollup
@@ -11,7 +11,7 @@ Description:
Additionally, the fields Pss_Anon, Pss_File and Pss_Shmem
are not present in /proc/pid/smaps.  These fields represent
the sum of the Pss field of each type (anon, file, shmem).
-   For more details, see Documentation/filesystems/proc.txt
+   For more details, see Documentation/filesystems/proc.rst
and the procfs man page.
 
Typical output looks like this:
diff --git a/Documentation/admin-guide/cpu-load.rst 
b/Documentation/admin-guide/cpu-load.rst
index 2d01ce43d2a2..ebdecf864080 100644
--- a/Documentation/admin-guide/cpu-load.rst
+++ b/Documentation/admin-guide/cpu-load.rst
@@ -105,7 +105,7 @@ References
 --
 
 - http://lkml.org/lkml/2007/2/12/6
-- Documentation/filesystems/proc.txt (1.8)
+- Documentation/filesystems/proc.rst (1.8)
 
 
 Thanks
diff --git a/Documentation/admin-guide/kernel-parameters.txt 
b/Documentation/admin-guide/kernel-parameters.txt
index 28be91d4e66b..192a36a66fc9 100644
--- a/Documentation/admin-guide/kernel-parameters.txt
+++ b/Documentation/admin-guide/kernel-parameters.txt
@@ -683,7 +683,7

[PATCH 08/12] docs: fix broken references to text files

2020-03-17 Thread Mauro Carvalho Chehab
Several references got broken due to txt to ReST conversion.

Several of them can be automatically fixed with:

scripts/documentation-file-ref-check --fix

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/admin-guide/kernel-parameters.txt  |  2 +-
 Documentation/memory-barriers.txt|  2 +-
 Documentation/process/submit-checklist.rst   |  2 +-
 .../translations/it_IT/process/submit-checklist.rst  |  2 +-
 Documentation/translations/ko_KR/memory-barriers.txt |  2 +-
 .../translations/zh_CN/filesystems/sysfs.txt |  2 +-
 .../translations/zh_CN/process/submit-checklist.rst  |  2 +-
 Documentation/virt/kvm/arm/pvtime.rst|  2 +-
 Documentation/virt/kvm/devices/vcpu.rst  |  2 +-
 Documentation/virt/kvm/hypercalls.rst|  4 ++--
 arch/powerpc/include/uapi/asm/kvm_para.h |  2 +-
 drivers/gpu/drm/Kconfig  |  2 +-
 drivers/gpu/drm/drm_ioctl.c  |  2 +-
 drivers/hwtracing/coresight/Kconfig  |  2 +-
 fs/fat/Kconfig   |  8 
 fs/fuse/Kconfig  |  2 +-
 fs/fuse/dev.c|  2 +-
 fs/overlayfs/Kconfig |  6 +++---
 include/linux/mm.h   |  4 ++--
 include/uapi/linux/ethtool_netlink.h |  2 +-
 include/uapi/rdma/rdma_user_ioctl_cmds.h |  2 +-
 mm/gup.c | 12 ++--
 virt/kvm/arm/vgic/vgic-mmio-v3.c |  2 +-
 virt/kvm/arm/vgic/vgic.h |  4 ++--
 24 files changed, 37 insertions(+), 37 deletions(-)

diff --git a/Documentation/admin-guide/kernel-parameters.txt 
b/Documentation/admin-guide/kernel-parameters.txt
index df34a4176e58..28be91d4e66b 100644
--- a/Documentation/admin-guide/kernel-parameters.txt
+++ b/Documentation/admin-guide/kernel-parameters.txt
@@ -960,7 +960,7 @@
edid/1680x1050.bin, or edid/1920x1080.bin is given
and no file with the same name exists. Details and
instructions how to build your own EDID data are
-   available in Documentation/driver-api/edid.rst. An EDID
+   available in Documentation/admin-guide/edid.rst. An EDID
data set will only be used for a particular connector,
if its name and a colon are prepended to the EDID
name. Each connector may use a unique EDID data
diff --git a/Documentation/memory-barriers.txt 
b/Documentation/memory-barriers.txt
index e1c355e84edd..eaabc3134294 100644
--- a/Documentation/memory-barriers.txt
+++ b/Documentation/memory-barriers.txt
@@ -620,7 +620,7 @@ because the CPUs that the Linux kernel supports don't do 
writes
 until they are certain (1) that the write will actually happen, (2)
 of the location of the write, and (3) of the value to be written.
 But please carefully read the "CONTROL DEPENDENCIES" section and the
-Documentation/RCU/rcu_dereference.txt file:  The compiler can and does
+Documentation/RCU/rcu_dereference.rst file:  The compiler can and does
 break dependencies in a great many highly creative ways.
 
CPU 1 CPU 2
diff --git a/Documentation/process/submit-checklist.rst 
b/Documentation/process/submit-checklist.rst
index 8e56337d422d..3f8e9d5d95c2 100644
--- a/Documentation/process/submit-checklist.rst
+++ b/Documentation/process/submit-checklist.rst
@@ -107,7 +107,7 @@ and elsewhere regarding submitting Linux kernel patches.
 and why.
 
 26) If any ioctl's are added by the patch, then also update
-``Documentation/ioctl/ioctl-number.rst``.
+``Documentation/userspace-api/ioctl/ioctl-number.rst``.
 
 27) If your modified source code depends on or uses any of the kernel
 APIs or features that are related to the following ``Kconfig`` symbols,
diff --git a/Documentation/translations/it_IT/process/submit-checklist.rst 
b/Documentation/translations/it_IT/process/submit-checklist.rst
index 995ee69fab11..3e575502690f 100644
--- a/Documentation/translations/it_IT/process/submit-checklist.rst
+++ b/Documentation/translations/it_IT/process/submit-checklist.rst
@@ -117,7 +117,7 @@ sottomissione delle patch, in particolare
 sorgenti che ne spieghi la logica: cosa fanno e perché.
 
 25) Se la patch aggiunge nuove chiamate ioctl, allora aggiornate
-``Documentation/ioctl/ioctl-number.rst``.
+``Documentation/userspace-api/ioctl/ioctl-number.rst``.
 
 26) Se il codice che avete modificato dipende o usa una qualsiasi interfaccia o
 funzionalità del kernel che è associata a uno dei seguenti simboli
diff --git a/Documentation/translations/ko_KR/memory-barriers.txt 
b/Documentation/translations/ko_KR/memory-barriers.txt
index 2e831ece6e26..e50fe6541

[PATCH v3 14/18] docs: powerpc: convert vcpudispatch_stats.txt to ReST

2020-03-03 Thread Mauro Carvalho Chehab
- Add a SPDX header;
- Use standard markup for document title;
- Adjust identation on lists and add blank lines where
  needed;
- Add it to the powerpc index.rst file.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/powerpc/index.rst |  1 +
 ...ispatch_stats.txt => vcpudispatch_stats.rst} | 17 -
 2 files changed, 13 insertions(+), 5 deletions(-)
 rename Documentation/powerpc/{vcpudispatch_stats.txt => 
vcpudispatch_stats.rst} (94%)

diff --git a/Documentation/powerpc/index.rst b/Documentation/powerpc/index.rst
index 0d45f0fc8e57..29b90b1b6f20 100644
--- a/Documentation/powerpc/index.rst
+++ b/Documentation/powerpc/index.rst
@@ -30,6 +30,7 @@ powerpc
 syscall64-abi
 transactional_memory
 ultravisor
+vcpudispatch_stats
 
 .. only::  subproject and html
 
diff --git a/Documentation/powerpc/vcpudispatch_stats.txt 
b/Documentation/powerpc/vcpudispatch_stats.rst
similarity index 94%
rename from Documentation/powerpc/vcpudispatch_stats.txt
rename to Documentation/powerpc/vcpudispatch_stats.rst
index e21476bfd78c..5704657a5987 100644
--- a/Documentation/powerpc/vcpudispatch_stats.txt
+++ b/Documentation/powerpc/vcpudispatch_stats.rst
@@ -1,5 +1,8 @@
-VCPU Dispatch Statistics:
-=
+.. SPDX-License-Identifier: GPL-2.0
+
+
+VCPU Dispatch Statistics
+
 
 For Shared Processor LPARs, the POWER Hypervisor maintains a relatively
 static mapping of the LPAR processors (vcpus) to physical processor
@@ -20,25 +23,29 @@ The statistics themselves are available by reading the 
procfs file
 a vcpu as represented by the first field, followed by 8 numbers.
 
 The first number corresponds to:
+
 1. total vcpu dispatches since the beginning of statistics collection
 
 The next 4 numbers represent vcpu dispatch dispersions:
+
 2. number of times this vcpu was dispatched on the same processor as last
time
 3. number of times this vcpu was dispatched on a different processor core
as last time, but within the same chip
 4. number of times this vcpu was dispatched on a different chip
 5. number of times this vcpu was dispatches on a different socket/drawer
-(next numa boundary)
+   (next numa boundary)
 
 The final 3 numbers represent statistics in relation to the home node of
 the vcpu:
+
 6. number of times this vcpu was dispatched in its home node (chip)
 7. number of times this vcpu was dispatched in a different node
 8. number of times this vcpu was dispatched in a node further away (numa
-distance)
+   distance)
+
+An example output::
 
-An example output:
 $ sudo cat /proc/powerpc/vcpudispatch_stats
 cpu0 6839 4126 2683 30 0 6821 18 0
 cpu1 2515 1274 1229 12 0 2509 6 0
-- 
2.24.1



[PATCH 3/7] docs: fix broken references to text files

2020-02-22 Thread Mauro Carvalho Chehab
Several references got broken due to txt to ReST conversion.

Several of them can be automatically fixed with:

scripts/documentation-file-ref-check --fix

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/admin-guide/kernel-parameters.txt  | 10 +-
 Documentation/filesystems/cifs/cifsroot.txt  |  2 +-
 Documentation/memory-barriers.txt|  2 +-
 Documentation/process/submit-checklist.rst   |  2 +-
 .../translations/it_IT/process/submit-checklist.rst  |  2 +-
 Documentation/translations/ko_KR/memory-barriers.txt |  2 +-
 .../translations/zh_CN/filesystems/sysfs.txt |  2 +-
 .../translations/zh_CN/process/submit-checklist.rst  |  2 +-
 Documentation/virt/kvm/arm/pvtime.rst|  2 +-
 Documentation/virt/kvm/devices/vcpu.rst  |  2 +-
 Documentation/virt/kvm/hypercalls.rst|  4 ++--
 arch/powerpc/include/uapi/asm/kvm_para.h |  2 +-
 drivers/gpu/drm/Kconfig  |  2 +-
 drivers/gpu/drm/drm_ioctl.c  |  2 +-
 drivers/hwtracing/coresight/Kconfig  |  2 +-
 fs/fat/Kconfig   |  8 
 fs/fuse/Kconfig  |  2 +-
 fs/fuse/dev.c|  2 +-
 fs/nfs/Kconfig   |  2 +-
 fs/overlayfs/Kconfig |  6 +++---
 include/linux/mm.h   |  4 ++--
 include/uapi/linux/ethtool_netlink.h |  2 +-
 include/uapi/rdma/rdma_user_ioctl_cmds.h |  2 +-
 mm/gup.c | 12 ++--
 net/ipv4/Kconfig |  6 +++---
 net/ipv4/ipconfig.c  |  2 +-
 virt/kvm/arm/vgic/vgic-mmio-v3.c |  2 +-
 virt/kvm/arm/vgic/vgic.h |  4 ++--
 28 files changed, 47 insertions(+), 47 deletions(-)

diff --git a/Documentation/admin-guide/kernel-parameters.txt 
b/Documentation/admin-guide/kernel-parameters.txt
index 8be1d0bbfd16..e0fe9f70d22b 100644
--- a/Documentation/admin-guide/kernel-parameters.txt
+++ b/Documentation/admin-guide/kernel-parameters.txt
@@ -957,7 +957,7 @@
edid/1680x1050.bin, or edid/1920x1080.bin is given
and no file with the same name exists. Details and
instructions how to build your own EDID data are
-   available in Documentation/driver-api/edid.rst. An EDID
+   available in Documentation/admin-guide/edid.rst. An EDID
data set will only be used for a particular connector,
if its name and a colon are prepended to the EDID
name. Each connector may use a unique EDID data
@@ -1884,7 +1884,7 @@
No delay
 
ip= [IP_PNP]
-   See Documentation/filesystems/nfs/nfsroot.txt.
+   See Documentation/admin-guide/nfs/nfsroot.rst.
 
ipcmni_extend   [KNL] Extend the maximum number of unique System V
IPC identifiers from 32,768 to 16,777,216.
@@ -2863,13 +2863,13 @@
Default value is 0.
 
nfsaddrs=   [NFS] Deprecated.  Use ip= instead.
-   See Documentation/filesystems/nfs/nfsroot.txt.
+   See Documentation/admin-guide/nfs/nfsroot.rst.
 
nfsroot=[NFS] nfs root filesystem for disk-less boxes.
-   See Documentation/filesystems/nfs/nfsroot.txt.
+   See Documentation/admin-guide/nfs/nfsroot.rst.
 
nfsrootdebug[NFS] enable nfsroot debugging messages.
-   See Documentation/filesystems/nfs/nfsroot.txt.
+   See Documentation/admin-guide/nfs/nfsroot.rst.
 
nfs.callback_nr_threads=
[NFSv4] set the total number of threads that the
diff --git a/Documentation/filesystems/cifs/cifsroot.txt 
b/Documentation/filesystems/cifs/cifsroot.txt
index 0fa1a2c36a40..947b7ec6ce9e 100644
--- a/Documentation/filesystems/cifs/cifsroot.txt
+++ b/Documentation/filesystems/cifs/cifsroot.txt
@@ -13,7 +13,7 @@ network by utilizing SMB or CIFS protocol.
 
 In order to mount, the network stack will also need to be set up by
 using 'ip=' config option. For more details, see
-Documentation/filesystems/nfs/nfsroot.txt.
+Documentation/admin-guide/nfs/nfsroot.rst.
 
 A CIFS root mount currently requires the use of SMB1+UNIX Extensions
 which is only supported by the Samba server. SMB1 is the older
diff --git a/Documentation/memory-barriers.txt 
b/Documentation/memory-barriers.txt
index e1c355e84edd..eaabc3134294 100644
--- a/Documentation/memory-barriers.txt
+++ b/Documentation/memory-barriers.txt
@@ -620,7 +620,7 @@ because the CPUs

[PATCH v2 00/24] Manually convert thermal, crypto and misc devices to ReST

2020-02-18 Thread Mauro Carvalho Chehab


Manually convert some files from thermal, crypto and misc-devices
to ReST format.

This patch is against linux-next 20200217 tag.

v2: 

- a small change at patch 2 to avoid uneeded whitespace changes;
- added 13 new patches at the end

Mauro Carvalho Chehab (24):
  docs: thermal: convert cpu-idle-cooling.rst to ReST
  docs: crypto: convert asymmetric-keys.txt to ReST
  docs: crypto: convert api-intro.txt to ReST format
  docs: crypto: convert async-tx-api.txt to ReST format
  docs: crypto: descore-readme.txt: convert to ReST format
  docs: misc-devices/spear-pcie-gadget.txt: convert to ReST
  docs: misc-devices/pci-endpoint-test.txt: convert to ReST
  docs: misc-devices/pci-endpoint-test.txt: convert to ReST
  docs: misc-devices/c2port.txt: convert to ReST format
  docs: misc-devices/bh1770glc.txt: convert to ReST
  docs: misc-devices/apds990x.txt: convert to ReST format
  docs: pci: endpoint/function/binding/pci-test.txt convert to ReST
  docs: arm64: convert perf.txt to ReST format
  docs: cpu-freq: convert index.txt to ReST
  docs: cpu-freq: convert amd-powernow.txt to ReST
  docs: cpu-freq: convert core.txt to ReST
  docs: cpu-freq: convert cpu-drivers.txt to ReST
  docs: cpu-freq: convert cpufreq-nforce2.txt to ReST
  docs: cpu-freq: convert cpufreq-stats.txt to ReST
  docs: cpu-freq: convert pcc-cpufreq.txt to ReST
  docs: powerpc: convert vcpudispatch_stats.txt to ReST
  docs: sh: convert new-machine.txt to ReST
  docs: sh: convert register-banks.txt to ReST
  docs: trace: ring-buffer-design.txt: convert to ReST format

 .../endpoint/function/binding/pci-test.rst|  26 +
 .../endpoint/function/binding/pci-test.txt|  19 -
 Documentation/PCI/endpoint/index.rst  |   2 +
 Documentation/arm64/index.rst |   1 +
 Documentation/arm64/{perf.txt => perf.rst}|   7 +-
 .../{amd-powernow.txt => amd-powernow.rst}|  12 +-
 Documentation/cpu-freq/{core.txt => core.rst} |  65 +-
 .../{cpu-drivers.txt => cpu-drivers.rst}  | 129 ++-
 ...pufreq-nforce2.txt => cpufreq-nforce2.rst} |  18 +-
 .../{cpufreq-stats.txt => cpufreq-stats.rst}  | 121 +--
 Documentation/cpu-freq/index.rst  |  42 +
 Documentation/cpu-freq/index.txt  |  56 --
 .../{pcc-cpufreq.txt => pcc-cpufreq.rst}  |  86 +-
 .../crypto/{api-intro.txt => api-intro.rst}   | 186 ++--
 ...symmetric-keys.txt => asymmetric-keys.rst} |  91 +-
 .../{async-tx-api.txt => async-tx-api.rst}| 253 +++---
 ...{descore-readme.txt => descore-readme.rst} | 152 +++-
 Documentation/crypto/index.rst|   5 +
 .../driver-api/thermal/cpu-idle-cooling.rst   |  18 +-
 Documentation/driver-api/thermal/index.rst|   1 +
 Documentation/index.rst   |   1 +
 .../{ad525x_dpot.txt => ad525x_dpot.rst}  |  24 +-
 .../{apds990x.txt => apds990x.rst}|  31 +-
 .../{bh1770glc.txt => bh1770glc.rst}  |  45 +-
 .../misc-devices/{c2port.txt => c2port.rst}   |  58 +-
 Documentation/misc-devices/index.rst  |   6 +
 .../misc-devices/pci-endpoint-test.rst|  56 ++
 .../misc-devices/pci-endpoint-test.txt|  41 -
 .../misc-devices/spear-pcie-gadget.rst| 170 
 .../misc-devices/spear-pcie-gadget.txt| 130 ---
 Documentation/powerpc/index.rst   |   1 +
 ...patch_stats.txt => vcpudispatch_stats.rst} |  17 +-
 Documentation/sh/index.rst|   6 +
 .../sh/{new-machine.txt => new-machine.rst}   | 193 +++--
 ...{register-banks.txt => register-banks.rst} |  12 +-
 Documentation/trace/index.rst |   1 +
 ...ffer-design.txt => ring-buffer-design.rst} | 802 ++
 37 files changed, 1603 insertions(+), 1281 deletions(-)
 create mode 100644 Documentation/PCI/endpoint/function/binding/pci-test.rst
 delete mode 100644 Documentation/PCI/endpoint/function/binding/pci-test.txt
 rename Documentation/arm64/{perf.txt => perf.rst} (95%)
 rename Documentation/cpu-freq/{amd-powernow.txt => amd-powernow.rst} (89%)
 rename Documentation/cpu-freq/{core.txt => core.rst} (69%)
 rename Documentation/cpu-freq/{cpu-drivers.txt => cpu-drivers.rst} (72%)
 rename Documentation/cpu-freq/{cpufreq-nforce2.txt => cpufreq-nforce2.rst} 
(55%)
 rename Documentation/cpu-freq/{cpufreq-stats.txt => cpufreq-stats.rst} (53%)
 create mode 100644 Documentation/cpu-freq/index.rst
 delete mode 100644 Documentation/cpu-freq/index.txt
 rename Documentation/cpu-freq/{pcc-cpufreq.txt => pcc-cpufreq.rst} (80%)
 rename Documentation/crypto/{api-intro.txt => api-intro.rst} (70%)
 rename Documentation/crypto/{asymmetric-keys.txt => asymmetric-keys.rst} (91%)
 rename Documentation/crypto/{async-tx-api.txt => async-tx-api.rst} (55%)
 rename Documentation/crypto/{descore-readme.txt => descore-readme.rst} (81%)
 rename Documentation/misc-devices/{ad525x_dpot.txt => ad525x_dpot.rst} (85%)
 rename Documentation/misc-devices/{apds990x.txt => apds9

[PATCH v2 21/24] docs: powerpc: convert vcpudispatch_stats.txt to ReST

2020-02-17 Thread Mauro Carvalho Chehab
- Add a SPDX header;
- Use standard markup for document title;
- Adjust identation on lists and add blank lines where
  needed;
- Add it to the powerpc index.rst file.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/powerpc/index.rst |  1 +
 ...ispatch_stats.txt => vcpudispatch_stats.rst} | 17 -
 2 files changed, 13 insertions(+), 5 deletions(-)
 rename Documentation/powerpc/{vcpudispatch_stats.txt => 
vcpudispatch_stats.rst} (94%)

diff --git a/Documentation/powerpc/index.rst b/Documentation/powerpc/index.rst
index 0d45f0fc8e57..29b90b1b6f20 100644
--- a/Documentation/powerpc/index.rst
+++ b/Documentation/powerpc/index.rst
@@ -30,6 +30,7 @@ powerpc
 syscall64-abi
 transactional_memory
 ultravisor
+vcpudispatch_stats
 
 .. only::  subproject and html
 
diff --git a/Documentation/powerpc/vcpudispatch_stats.txt 
b/Documentation/powerpc/vcpudispatch_stats.rst
similarity index 94%
rename from Documentation/powerpc/vcpudispatch_stats.txt
rename to Documentation/powerpc/vcpudispatch_stats.rst
index e21476bfd78c..5704657a5987 100644
--- a/Documentation/powerpc/vcpudispatch_stats.txt
+++ b/Documentation/powerpc/vcpudispatch_stats.rst
@@ -1,5 +1,8 @@
-VCPU Dispatch Statistics:
-=
+.. SPDX-License-Identifier: GPL-2.0
+
+
+VCPU Dispatch Statistics
+
 
 For Shared Processor LPARs, the POWER Hypervisor maintains a relatively
 static mapping of the LPAR processors (vcpus) to physical processor
@@ -20,25 +23,29 @@ The statistics themselves are available by reading the 
procfs file
 a vcpu as represented by the first field, followed by 8 numbers.
 
 The first number corresponds to:
+
 1. total vcpu dispatches since the beginning of statistics collection
 
 The next 4 numbers represent vcpu dispatch dispersions:
+
 2. number of times this vcpu was dispatched on the same processor as last
time
 3. number of times this vcpu was dispatched on a different processor core
as last time, but within the same chip
 4. number of times this vcpu was dispatched on a different chip
 5. number of times this vcpu was dispatches on a different socket/drawer
-(next numa boundary)
+   (next numa boundary)
 
 The final 3 numbers represent statistics in relation to the home node of
 the vcpu:
+
 6. number of times this vcpu was dispatched in its home node (chip)
 7. number of times this vcpu was dispatched in a different node
 8. number of times this vcpu was dispatched in a node further away (numa
-distance)
+   distance)
+
+An example output::
 
-An example output:
 $ sudo cat /proc/powerpc/vcpudispatch_stats
 cpu0 6839 4126 2683 30 0 6821 18 0
 cpu1 2515 1274 1229 12 0 2509 6 0
-- 
2.24.1



Re: [PATCH v2 00/26] ReST conversion of text files without .txt extension

2019-07-26 Thread Mauro Carvalho Chehab
Em Fri, 26 Jul 2019 09:51:10 -0300
Mauro Carvalho Chehab  escreveu:

> This series converts the text files under Documentation with doesn't end
> neither .txt or .rst and are not part of ABI or features.
> 
> This series is at:
>   https://git.linuxtv.org/mchehab/experimental.git/log/?h=rst_for_5_4_v3
> 
> And it is based on yesterday's upstream tree.
> 
> After this series, we have ~320 files left to be converted to ReST.
> 
> v2:
>   - Added 3 files submitted for v5.3 that weren't merged yet;
>   - markdown patch broken into two, per Rob's request;
>   - rebased on the top of upstream master branch
> 
> Mauro Carvalho Chehab (26):

>   docs: ABI: remove extension from sysfs-class-mic.txt

^ In time: this one was already merged.

Thanks,
Mauro


[PATCH v2 03/26] docs: powerpc: convert docs to ReST and rename to *.rst

2019-07-26 Thread Mauro Carvalho Chehab
Convert docs to ReST and add them to the arch-specific
book.

The conversion here was trivial, as almost every file there
was already using an elegant format close to ReST standard.

The changes were mostly to mark literal blocks and add a few
missing section title identifiers.

One note with regards to "--": on Sphinx, this can't be used
to identify a list, as it will format it badly. This can be
used, however, to identify a long hyphen - and "---" is an
even longer one.

At its new index.rst, let's add a :orphan: while this is not linked to
the main index.rst file, in order to avoid build warnings.

Signed-off-by: Mauro Carvalho Chehab 
Acked-by: Andrew Donnellan  # cxl
---
 Documentation/PCI/pci-error-recovery.rst  |   2 +-
 Documentation/index.rst   |   1 +
 .../{bootwrapper.txt => bootwrapper.rst}  |  28 ++-
 .../{cpu_families.txt => cpu_families.rst}|  23 +--
 .../{cpu_features.txt => cpu_features.rst}|   6 +-
 Documentation/powerpc/{cxl.txt => cxl.rst}|  46 +++--
 .../powerpc/{cxlflash.txt => cxlflash.rst}|  10 +-
 .../{DAWR-POWER9.txt => dawr-power9.rst}  |  15 +-
 Documentation/powerpc/{dscr.txt => dscr.rst}  |  18 +-
 ...ecovery.txt => eeh-pci-error-recovery.rst} | 108 +--
 ...ed-dump.txt => firmware-assisted-dump.rst} | 117 ++--
 Documentation/powerpc/{hvcs.txt => hvcs.rst}  | 108 ++-
 Documentation/powerpc/index.rst   |  34 
 Documentation/powerpc/isa-versions.rst|  15 +-
 .../powerpc/{mpc52xx.txt => mpc52xx.rst}  |  12 +-
 ...nv.txt => pci_iov_resource_on_powernv.rst} |  15 +-
 .../powerpc/{pmu-ebb.txt => pmu-ebb.rst}  |   1 +
 .../powerpc/{ptrace.txt => ptrace.rst}| 169 +-
 .../{qe_firmware.txt => qe_firmware.rst}  |  37 ++--
 .../{syscall64-abi.txt => syscall64-abi.rst}  |  29 +--
 ...al_memory.txt => transactional_memory.rst} |  45 ++---
 MAINTAINERS   |   6 +-
 arch/powerpc/kernel/exceptions-64s.S  |   2 +-
 drivers/soc/fsl/qe/qe.c   |   2 +-
 drivers/tty/hvc/hvcs.c|   2 +-
 include/soc/fsl/qe/qe.h   |   2 +-
 26 files changed, 495 insertions(+), 358 deletions(-)
 rename Documentation/powerpc/{bootwrapper.txt => bootwrapper.rst} (93%)
 rename Documentation/powerpc/{cpu_families.txt => cpu_families.rst} (95%)
 rename Documentation/powerpc/{cpu_features.txt => cpu_features.rst} (97%)
 rename Documentation/powerpc/{cxl.txt => cxl.rst} (95%)
 rename Documentation/powerpc/{cxlflash.txt => cxlflash.rst} (98%)
 rename Documentation/powerpc/{DAWR-POWER9.txt => dawr-power9.rst} (95%)
 rename Documentation/powerpc/{dscr.txt => dscr.rst} (91%)
 rename Documentation/powerpc/{eeh-pci-error-recovery.txt => 
eeh-pci-error-recovery.rst} (82%)
 rename Documentation/powerpc/{firmware-assisted-dump.txt => 
firmware-assisted-dump.rst} (80%)
 rename Documentation/powerpc/{hvcs.txt => hvcs.rst} (91%)
 create mode 100644 Documentation/powerpc/index.rst
 rename Documentation/powerpc/{mpc52xx.txt => mpc52xx.rst} (91%)
 rename Documentation/powerpc/{pci_iov_resource_on_powernv.txt => 
pci_iov_resource_on_powernv.rst} (97%)
 rename Documentation/powerpc/{pmu-ebb.txt => pmu-ebb.rst} (99%)
 rename Documentation/powerpc/{ptrace.txt => ptrace.rst} (48%)
 rename Documentation/powerpc/{qe_firmware.txt => qe_firmware.rst} (95%)
 rename Documentation/powerpc/{syscall64-abi.txt => syscall64-abi.rst} (82%)
 rename Documentation/powerpc/{transactional_memory.txt => 
transactional_memory.rst} (93%)

diff --git a/Documentation/PCI/pci-error-recovery.rst 
b/Documentation/PCI/pci-error-recovery.rst
index 83db42092935..69800a9d1b0d 100644
--- a/Documentation/PCI/pci-error-recovery.rst
+++ b/Documentation/PCI/pci-error-recovery.rst
@@ -403,7 +403,7 @@ That is, the recovery API only requires that:
 .. note::
 
Implementation details for the powerpc platform are discussed in
-   the file Documentation/powerpc/eeh-pci-error-recovery.txt
+   the file Documentation/powerpc/eeh-pci-error-recovery.rst
 
As of this writing, there is a growing list of device drivers with
patches implementing error recovery. Not all of these patches are in
diff --git a/Documentation/index.rst b/Documentation/index.rst
index 230e550e9741..68ae2a4d689d 100644
--- a/Documentation/index.rst
+++ b/Documentation/index.rst
@@ -144,6 +144,7 @@ implementation.
arm64/index
ia64/index
m68k/index
+   powerpc/index
riscv/index
s390/index
sh/index
diff --git a/Documentation/powerpc/bootwrapper.txt 
b/Documentation/powerpc/bootwrapper.rst
similarity index 93%
rename from Documentation/powerpc/bootwrapper.txt
rename to Documentation/powerpc/bootwrapper.rst
index d60fced5e1cc..a6292afba573 100644
--- a/Documentation/powerpc/bootw

[PATCH v2 00/26] ReST conversion of text files without .txt extension

2019-07-26 Thread Mauro Carvalho Chehab
This series converts the text files under Documentation with doesn't end
neither .txt or .rst and are not part of ABI or features.

This series is at:
https://git.linuxtv.org/mchehab/experimental.git/log/?h=rst_for_5_4_v3

And it is based on yesterday's upstream tree.

After this series, we have ~320 files left to be converted to ReST.

v2:
  - Added 3 files submitted for v5.3 that weren't merged yet;
  - markdown patch broken into two, per Rob's request;
  - rebased on the top of upstream master branch

Mauro Carvalho Chehab (26):
  docs: power: add it to to the main documentation index
  docs: thermal: add it to the driver API
  docs: powerpc: convert docs to ReST and rename to *.rst
  docs: ubifs-authentication.md: convert to ReST
  docs: writing-schema.md: convert from markdown to ReST
  docs: i2c: convert to ReST and add to driver-api bookset
  docs: w1: convert to ReST and add to the kAPI group of docs
  spi: docs: convert to ReST and add it to the kABI bookset
  docs: ipmb: place it at driver-api and convert to ReST
  docs: packing: move it to core-api book and adjust markups
  docs: admin-guide: add auxdisplay files to it after conversion to ReST
  docs: README.buddha: convert to ReST and add to m68k book
  docs: parisc: convert to ReST and add to documentation body
  docs: openrisc: convert to ReST and add to documentation body
  docs: isdn: convert to ReST and add to kAPI bookset
  docs: fs: cifs: convert to ReST and add to admin-guide book
  docs: fs: convert docs without extension to ReST
  docs: fs: convert porting to ReST
  docs: index.rst: don't use genindex for pdf output
  docs: wimax: convert to ReST and add to admin-guide
  docs: mips: add to the documentation body as ReST
  docs: hwmon: pxe1610: convert to ReST format and add to the index
  docs: nios2: add it to the main Documentation body
  docs: net: convert two README files to ReST format
  docs: rcu: convert some articles from html to ReST
  docs: ABI: remove extension from sysfs-class-mic.txt

 Documentation/ABI/stable/sysfs-bus-w1 |2 +-
 .../ABI/stable/sysfs-driver-w1_ds28e04|4 +-
 .../ABI/stable/sysfs-driver-w1_ds28ea00   |2 +-
 .../{sysfs-class-mic.txt => sysfs-class-mic}  |0
 Documentation/PCI/pci-error-recovery.rst  |2 +-
 .../Data-Structures/Data-Structures.html  | 1391 ---
 .../Data-Structures/Data-Structures.rst   | 1163 ++
 ...riods.html => Expedited-Grace-Periods.rst} |  949 ++---
 .../Memory-Ordering/Tree-RCU-Diagram.html |9 -
 ...ring.html => Tree-RCU-Memory-Ordering.rst} | 1181 +++---
 .../RCU/Design/Requirements/Requirements.html | 3330 -
 .../RCU/Design/Requirements/Requirements.rst  | 2662 +
 Documentation/RCU/index.rst   |5 +
 Documentation/RCU/whatisRCU.txt   |4 +-
 .../auxdisplay/cfag12864b.rst}|  115 +-
 .../admin-guide/auxdisplay/index.rst  |   16 +
 .../auxdisplay/ks0108.rst}|   53 +-
 .../AUTHORS => admin-guide/cifs/authors.rst}  |   64 +-
 .../CHANGES => admin-guide/cifs/changes.rst}  |4 +
 Documentation/admin-guide/cifs/index.rst  |   21 +
 .../cifs/introduction.rst}|8 +
 .../cifs/TODO => admin-guide/cifs/todo.rst}   |   87 +-
 .../README => admin-guide/cifs/usage.rst} |  560 +--
 .../cifs/winucase_convert.pl  |0
 Documentation/admin-guide/index.rst   |3 +
 .../wimax/i2400m.rst} |  145 +-
 Documentation/admin-guide/wimax/index.rst |   19 +
 .../wimax/wimax.rst}  |   36 +-
 Documentation/core-api/index.rst  |3 +-
 .../{packing.txt => core-api/packing.rst} |   81 +-
 .../devicetree/bindings/i2c/i2c-mux-gpmux.txt |2 +-
 .../{writing-schema.md => writing-schema.rst} |  137 +-
 Documentation/driver-api/dmaengine/index.rst  |2 +-
 Documentation/driver-api/index.rst|2 +
 Documentation/driver-api/ipmb.rst |2 +-
 Documentation/driver-api/soundwire/index.rst  |2 +-
 .../thermal/cpu-cooling-api.rst   |0
 .../thermal/exynos_thermal.rst|0
 .../thermal/exynos_thermal_emulation.rst  |0
 .../{ => driver-api}/thermal/index.rst|2 +-
 .../thermal/intel_powerclamp.rst  |0
 .../thermal/nouveau_thermal.rst   |0
 .../thermal/power_allocator.rst   |0
 .../{ => driver-api}/thermal/sysfs-api.rst|   12 +-
 .../thermal/x86_pkg_temperature_thermal.rst   |2 +-
 ...irectory-locking => directory-locking.rst} |   40 +-
 Documentation/filesystems/index.rst   |4 +
 .../filesystems/{Locking => locking.rst}  |  257 +-
 .../nfs/{Exporting => exporting.rst}  |   31 +-
 .../filesystems/{porting => porting.rst}  |  824 ++--
 ...entication.md => ubifs-authentication.rst} |   70 +-
 Docu

[PATCH v4 12/15] docs: ABI: stable: make files ReST compatible

2019-07-17 Thread Mauro Carvalho Chehab
Several entries at the stable ABI files won't parse if we pass
them directly to the ReST output.

Adjust them, in order to allow adding their contents as-is at
the stable ABI book.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/ABI/stable/firewire-cdev|  4 +
 Documentation/ABI/stable/sysfs-acpi-pmprofile | 22 +++--
 Documentation/ABI/stable/sysfs-bus-firewire   |  3 +
 Documentation/ABI/stable/sysfs-bus-nvmem  | 19 ++--
 Documentation/ABI/stable/sysfs-bus-usb|  6 +-
 .../ABI/stable/sysfs-class-backlight  |  1 +
 .../ABI/stable/sysfs-class-infiniband | 95 +--
 Documentation/ABI/stable/sysfs-class-rfkill   | 13 ++-
 Documentation/ABI/stable/sysfs-class-tpm  | 90 +-
 Documentation/ABI/stable/sysfs-devices|  5 +-
 Documentation/ABI/stable/sysfs-driver-ib_srp  |  1 +
 .../ABI/stable/sysfs-firmware-efi-vars|  4 +
 .../ABI/stable/sysfs-firmware-opal-dump   |  5 +
 .../ABI/stable/sysfs-firmware-opal-elog   |  2 +
 Documentation/ABI/stable/sysfs-hypervisor-xen |  3 +
 Documentation/ABI/stable/vdso |  5 +-
 Documentation/admin-guide/abi-stable.rst  |  1 +
 17 files changed, 179 insertions(+), 100 deletions(-)

diff --git a/Documentation/ABI/stable/firewire-cdev 
b/Documentation/ABI/stable/firewire-cdev
index f72ed653878a..c9e8ff026154 100644
--- a/Documentation/ABI/stable/firewire-cdev
+++ b/Documentation/ABI/stable/firewire-cdev
@@ -14,12 +14,14 @@ Description:
Each /dev/fw* is associated with one IEEE 1394 node, which can
be remote or local nodes.  Operations on a /dev/fw* file have
different scope:
+
  - The 1394 node which is associated with the file:
  - Asynchronous request transmission
  - Get the Configuration ROM
  - Query node ID
  - Query maximum speed of the path between this node
and local node
+
  - The 1394 bus (i.e. "card") to which the node is attached to:
  - Isochronous stream transmission and reception
  - Asynchronous stream transmission and reception
@@ -31,6 +33,7 @@ Description:
manager
  - Query cycle time
  - Bus reset initiation, bus reset event reception
+
  - All 1394 buses:
  - Allocation of IEEE 1212 address ranges on the local
link layers, reception of inbound requests to such
@@ -43,6 +46,7 @@ Description:
userland implement different access permission models, some
operations are restricted to /dev/fw* files that are associated
with a local node:
+
  - Addition of descriptors or directories to the local
nodes' Configuration ROM
  - PHY packet transmission and reception
diff --git a/Documentation/ABI/stable/sysfs-acpi-pmprofile 
b/Documentation/ABI/stable/sysfs-acpi-pmprofile
index 964c7a8afb26..fd97d22b677f 100644
--- a/Documentation/ABI/stable/sysfs-acpi-pmprofile
+++ b/Documentation/ABI/stable/sysfs-acpi-pmprofile
@@ -6,17 +6,21 @@ Description:  The ACPI pm_profile sysfs interface exports the 
platform
power management (and performance) requirement expectations
as provided by BIOS. The integer value is directly passed as
retrieved from the FADT ACPI table.
-Values: For possible values see ACPI specification:
+
+Values:For possible values see ACPI specification:
5.2.9 Fixed ACPI Description Table (FADT)
Field: Preferred_PM_Profile
 
Currently these values are defined by spec:
-   0 Unspecified
-   1 Desktop
-   2 Mobile
-   3 Workstation
-   4 Enterprise Server
-   5 SOHO Server
-   6 Appliance PC
-   7 Performance Server
+
+   == =
+   0  Unspecified
+   1  Desktop
+   2  Mobile
+   3  Workstation
+   4  Enterprise Server
+   5  SOHO Server
+   6  Appliance PC
+   7  Performance Server
>7 Reserved
+   == =
diff --git a/Documentation/ABI/stable/sysfs-bus-firewire 
b/Documentation/ABI/stable/sysfs-bus-firewire
index 41e5a0cd1e3e..9ac9eddb82ef 100644
--- a/Documentation/ABI/stable/sysfs-bus-firewire
+++ b/Documentation/ABI/stable/sysfs-bus-firewire
@@ -47,6 +47,7 @@ Description:
IEEE 1394 node device attribute.
Read-only and immutable.
 Values:1: The sysfs entry represents a local node (a 
co

[PATCH v3 14/20] docs: ABI: stable: make files ReST compatible

2019-07-17 Thread Mauro Carvalho Chehab
Several entries at the stable ABI files won't parse if we pass
them directly to the ReST output.

Adjust them, in order to allow adding their contents as-is at
the stable ABI book.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/ABI/stable/firewire-cdev|  4 +
 Documentation/ABI/stable/sysfs-acpi-pmprofile | 22 +++--
 Documentation/ABI/stable/sysfs-bus-firewire   |  3 +
 Documentation/ABI/stable/sysfs-bus-nvmem  | 19 ++--
 Documentation/ABI/stable/sysfs-bus-usb|  6 +-
 .../ABI/stable/sysfs-class-backlight  |  1 +
 .../ABI/stable/sysfs-class-infiniband | 95 +--
 Documentation/ABI/stable/sysfs-class-rfkill   | 13 ++-
 Documentation/ABI/stable/sysfs-class-tpm  | 90 +-
 Documentation/ABI/stable/sysfs-devices|  5 +-
 Documentation/ABI/stable/sysfs-driver-ib_srp  |  1 +
 .../ABI/stable/sysfs-firmware-efi-vars|  4 +
 .../ABI/stable/sysfs-firmware-opal-dump   |  5 +
 .../ABI/stable/sysfs-firmware-opal-elog   |  2 +
 Documentation/ABI/stable/sysfs-hypervisor-xen |  3 +
 Documentation/ABI/stable/vdso |  5 +-
 16 files changed, 178 insertions(+), 100 deletions(-)

diff --git a/Documentation/ABI/stable/firewire-cdev 
b/Documentation/ABI/stable/firewire-cdev
index f72ed653878a..c9e8ff026154 100644
--- a/Documentation/ABI/stable/firewire-cdev
+++ b/Documentation/ABI/stable/firewire-cdev
@@ -14,12 +14,14 @@ Description:
Each /dev/fw* is associated with one IEEE 1394 node, which can
be remote or local nodes.  Operations on a /dev/fw* file have
different scope:
+
  - The 1394 node which is associated with the file:
  - Asynchronous request transmission
  - Get the Configuration ROM
  - Query node ID
  - Query maximum speed of the path between this node
and local node
+
  - The 1394 bus (i.e. "card") to which the node is attached to:
  - Isochronous stream transmission and reception
  - Asynchronous stream transmission and reception
@@ -31,6 +33,7 @@ Description:
manager
  - Query cycle time
  - Bus reset initiation, bus reset event reception
+
  - All 1394 buses:
  - Allocation of IEEE 1212 address ranges on the local
link layers, reception of inbound requests to such
@@ -43,6 +46,7 @@ Description:
userland implement different access permission models, some
operations are restricted to /dev/fw* files that are associated
with a local node:
+
  - Addition of descriptors or directories to the local
nodes' Configuration ROM
  - PHY packet transmission and reception
diff --git a/Documentation/ABI/stable/sysfs-acpi-pmprofile 
b/Documentation/ABI/stable/sysfs-acpi-pmprofile
index 964c7a8afb26..fd97d22b677f 100644
--- a/Documentation/ABI/stable/sysfs-acpi-pmprofile
+++ b/Documentation/ABI/stable/sysfs-acpi-pmprofile
@@ -6,17 +6,21 @@ Description:  The ACPI pm_profile sysfs interface exports the 
platform
power management (and performance) requirement expectations
as provided by BIOS. The integer value is directly passed as
retrieved from the FADT ACPI table.
-Values: For possible values see ACPI specification:
+
+Values:For possible values see ACPI specification:
5.2.9 Fixed ACPI Description Table (FADT)
Field: Preferred_PM_Profile
 
Currently these values are defined by spec:
-   0 Unspecified
-   1 Desktop
-   2 Mobile
-   3 Workstation
-   4 Enterprise Server
-   5 SOHO Server
-   6 Appliance PC
-   7 Performance Server
+
+   == =
+   0  Unspecified
+   1  Desktop
+   2  Mobile
+   3  Workstation
+   4  Enterprise Server
+   5  SOHO Server
+   6  Appliance PC
+   7  Performance Server
>7 Reserved
+   == =
diff --git a/Documentation/ABI/stable/sysfs-bus-firewire 
b/Documentation/ABI/stable/sysfs-bus-firewire
index 41e5a0cd1e3e..9ac9eddb82ef 100644
--- a/Documentation/ABI/stable/sysfs-bus-firewire
+++ b/Documentation/ABI/stable/sysfs-bus-firewire
@@ -47,6 +47,7 @@ Description:
IEEE 1394 node device attribute.
Read-only and immutable.
 Values:1: The sysfs entry represents a local node (a 
controller card).
+
0: The sysfs entry represents 

[PATCH 01/14] docs: powerpc: convert docs to ReST and rename to *.rst

2019-07-16 Thread Mauro Carvalho Chehab
Convert docs to ReST and add them to the arch-specific
book.

The conversion here was trivial, as almost every file there
was already using an elegant format close to ReST standard.

The changes were mostly to mark literal blocks and add a few
missing section title identifiers.

One note with regards to "--": on Sphinx, this can't be used
to identify a list, as it will format it badly. This can be
used, however, to identify a long hyphen - and "---" is an
even longer one.

At its new index.rst, let's add a :orphan: while this is not linked to
the main index.rst file, in order to avoid build warnings.

Signed-off-by: Mauro Carvalho Chehab 
Acked-by: Andrew Donnellan  # cxl
---
 Documentation/PCI/pci-error-recovery.rst  |   5 +-
 Documentation/index.rst   |   1 +
 .../{bootwrapper.txt => bootwrapper.rst}  |  28 +++-
 .../{cpu_families.txt => cpu_families.rst}|  23 +--
 .../{cpu_features.txt => cpu_features.rst}|   6 +-
 Documentation/powerpc/{cxl.txt => cxl.rst}|  46 --
 .../powerpc/{cxlflash.txt => cxlflash.rst}|  10 +-
 .../{DAWR-POWER9.txt => dawr-power9.rst}  |  15 +-
 Documentation/powerpc/{dscr.txt => dscr.rst}  |  18 +-
 ...ecovery.txt => eeh-pci-error-recovery.rst} | 108 ++--
 ...ed-dump.txt => firmware-assisted-dump.rst} | 117 +++--
 Documentation/powerpc/{hvcs.txt => hvcs.rst}  | 108 ++--
 Documentation/powerpc/index.rst   |  34 
 Documentation/powerpc/isa-versions.rst|  15 +-
 .../powerpc/{mpc52xx.txt => mpc52xx.rst}  |  12 +-
 ...nv.txt => pci_iov_resource_on_powernv.rst} |  15 +-
 .../powerpc/{pmu-ebb.txt => pmu-ebb.rst}  |   1 +
 Documentation/powerpc/ptrace.rst  | 156 ++
 Documentation/powerpc/ptrace.txt  | 151 -
 .../{qe_firmware.txt => qe_firmware.rst}  |  37 +++--
 .../{syscall64-abi.txt => syscall64-abi.rst}  |  29 ++--
 ...al_memory.txt => transactional_memory.rst} |  45 ++---
 MAINTAINERS   |   6 +-
 arch/powerpc/kernel/exceptions-64s.S  |   2 +-
 drivers/soc/fsl/qe/qe.c   |   2 +-
 drivers/tty/hvc/hvcs.c|   2 +-
 include/soc/fsl/qe/qe.h   |   2 +-
 27 files changed, 567 insertions(+), 427 deletions(-)
 rename Documentation/powerpc/{bootwrapper.txt => bootwrapper.rst} (93%)
 rename Documentation/powerpc/{cpu_families.txt => cpu_families.rst} (95%)
 rename Documentation/powerpc/{cpu_features.txt => cpu_features.rst} (97%)
 rename Documentation/powerpc/{cxl.txt => cxl.rst} (95%)
 rename Documentation/powerpc/{cxlflash.txt => cxlflash.rst} (98%)
 rename Documentation/powerpc/{DAWR-POWER9.txt => dawr-power9.rst} (95%)
 rename Documentation/powerpc/{dscr.txt => dscr.rst} (91%)
 rename Documentation/powerpc/{eeh-pci-error-recovery.txt => 
eeh-pci-error-recovery.rst} (82%)
 rename Documentation/powerpc/{firmware-assisted-dump.txt => 
firmware-assisted-dump.rst} (80%)
 rename Documentation/powerpc/{hvcs.txt => hvcs.rst} (91%)
 create mode 100644 Documentation/powerpc/index.rst
 rename Documentation/powerpc/{mpc52xx.txt => mpc52xx.rst} (91%)
 rename Documentation/powerpc/{pci_iov_resource_on_powernv.txt => 
pci_iov_resource_on_powernv.rst} (97%)
 rename Documentation/powerpc/{pmu-ebb.txt => pmu-ebb.rst} (99%)
 create mode 100644 Documentation/powerpc/ptrace.rst
 delete mode 100644 Documentation/powerpc/ptrace.txt
 rename Documentation/powerpc/{qe_firmware.txt => qe_firmware.rst} (95%)
 rename Documentation/powerpc/{syscall64-abi.txt => syscall64-abi.rst} (82%)
 rename Documentation/powerpc/{transactional_memory.txt => 
transactional_memory.rst} (93%)

diff --git a/Documentation/PCI/pci-error-recovery.rst 
b/Documentation/PCI/pci-error-recovery.rst
index 83db42092935..e5d450df06b4 100644
--- a/Documentation/PCI/pci-error-recovery.rst
+++ b/Documentation/PCI/pci-error-recovery.rst
@@ -403,7 +403,7 @@ That is, the recovery API only requires that:
 .. note::
 
Implementation details for the powerpc platform are discussed in
-   the file Documentation/powerpc/eeh-pci-error-recovery.txt
+   the file Documentation/powerpc/eeh-pci-error-recovery.rst
 
As of this writing, there is a growing list of device drivers with
patches implementing error recovery. Not all of these patches are in
@@ -422,3 +422,6 @@ That is, the recovery API only requires that:
- drivers/net/cxgb3
- drivers/net/s2io.c
- drivers/net/qlge
+
+The End
+---
diff --git a/Documentation/index.rst b/Documentation/index.rst
index 70ae148ec980..3fe6170aa41d 100644
--- a/Documentation/index.rst
+++ b/Documentation/index.rst
@@ -143,6 +143,7 @@ implementation.
arm64/index
ia64/index
m68k/index
+   powerpc/index
riscv/index
s390/index
sh/index
diff --git a/Documentation/powerpc/bootwrapper.txt 
b/Documentation/po

[PATCH 00/14] pending doc patches for 5.3-rc

2019-07-16 Thread Mauro Carvalho Chehab
Those are the pending documentation patches after my pull request
for this branch:

git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media.git 
tags/docs/v5.3-1

Patches 1 to 13 were already submitted, but got rebased. Patch 14
is a new fixup one.

Patches 1 and 2 weren't submitted before due to merge conflicts
that are now solved upstream;

Patch 3 fixes a series of random Documentation/* references that
are pointing to the wrong places.

Patch 4 fix a longstanding issue: every time a new book is added,
conf.py need changes, in order to allow generating a PDF file.
After the patch, conf.py will automatically recognize new books,
saving the trouble of keeping adding documents to it.

Patches 5 to 11 are due to fonts support when building translations.pdf.
The main focus is to add xeCJK support. While doing it, I discovered
some bugs at sphinx-pre-install script after running it with 7 different
distributions.

Patch 12 improves support for partial doc building. Currently, each
subdir needs to have its own conf.py, in order to support partial
doc build. After it, any Documentation subdir can be used to 
roduce html/pdf docs with:

make SPHINXDIRS="foo bar" htmldocs
(or pdfdocs, latexdocs, epubdocs, ...)

Patch 13 is a cleanup patch: it simply get rid of all those extra
conf.py files that  aren't needed anymore. The only extra config
file after it is this one:

Documentation/media/conf_nitpick.py

With enables some extra optional Sphinx features.

Patch 14 adds Documentation/virtual to the main index.rst file
and add a new *.rst file that was orphaned there.

-

After this series, there's just one more patch meant to be applied
for 5.3, with is still waiting for some patches to be merged from
linux-next:


https://git.linuxtv.org/mchehab/experimental.git/commit/?id=b1b5dc7d7bbfbbfdace2a248c6458301c6e34100


Mauro Carvalho Chehab (14):
  docs: powerpc: convert docs to ReST and rename to *.rst
  docs: power: add it to to the main documentation index
  docs: fix broken doc references due to renames
  docs: pdf: add all Documentation/*/index.rst to PDF output
  docs: conf.py: add CJK package needed by translations
  docs: conf.py: only use CJK if the font is available
  scripts/sphinx-pre-install: fix script for RHEL/CentOS
  scripts/sphinx-pre-install: don't use LaTeX with CentOS 7
  scripts/sphinx-pre-install: fix latexmk dependencies
  scripts/sphinx-pre-install: cleanup Gentoo checks
  scripts/sphinx-pre-install: seek for Noto CJK fonts for pdf output
  docs: load_config.py: avoid needing a conf.py just due to LaTeX docs
  docs: remove extra conf.py files
  docs: virtual: add it to the documentation body

 Documentation/PCI/pci-error-recovery.rst  |   5 +-
 Documentation/RCU/rculist_nulls.txt   |   2 +-
 Documentation/admin-guide/conf.py |  10 --
 Documentation/conf.py |  30 +++-
 Documentation/core-api/conf.py|  10 --
 Documentation/crypto/conf.py  |  10 --
 Documentation/dev-tools/conf.py   |  10 --
 .../devicetree/bindings/arm/idle-states.txt   |   2 +-
 Documentation/doc-guide/conf.py   |  10 --
 Documentation/driver-api/80211/conf.py|  10 --
 Documentation/driver-api/conf.py  |  10 --
 Documentation/driver-api/pm/conf.py   |  10 --
 Documentation/filesystems/conf.py |  10 --
 Documentation/gpu/conf.py |  10 --
 Documentation/index.rst   |   3 +
 Documentation/input/conf.py   |  10 --
 Documentation/kernel-hacking/conf.py  |  10 --
 Documentation/locking/spinlocks.rst   |   4 +-
 Documentation/maintainer/conf.py  |  10 --
 Documentation/media/conf.py   |  12 --
 Documentation/memory-barriers.txt |   2 +-
 Documentation/networking/conf.py  |  10 --
 Documentation/power/index.rst |   2 +-
 .../{bootwrapper.txt => bootwrapper.rst}  |  28 +++-
 .../{cpu_families.txt => cpu_families.rst}|  23 +--
 .../{cpu_features.txt => cpu_features.rst}|   6 +-
 Documentation/powerpc/{cxl.txt => cxl.rst}|  46 --
 .../powerpc/{cxlflash.txt => cxlflash.rst}|  10 +-
 .../{DAWR-POWER9.txt => dawr-power9.rst}  |  15 +-
 Documentation/powerpc/{dscr.txt => dscr.rst}  |  18 +-
 ...ecovery.txt => eeh-pci-error-recovery.rst} | 108 ++--
 ...ed-dump.txt => firmware-assisted-dump.rst} | 117 +++--
 Documentation/powerpc/{hvcs.txt => hvcs.rst}  | 108 ++--
 Documentation/powerpc/index.rst   |  34 
 Documentation/powerpc/isa-versions.rst|  15 +-
 .../powerpc/{mpc52xx.txt => mpc52xx.rst}  |  12 +-
 ...nv.txt => pci_iov_resource_on_powernv.rst} |  15 +-
 .../powerpc/{pmu-ebb.txt => pmu-ebb.rst}  |   1 +
 Documentation/powerpc/ptrace.rst  | 156 ++
 Do

Re: [PATCH 18/39] docs: admin-guide: add kdump documentation into it

2019-07-06 Thread Mauro Carvalho Chehab
Em Fri, 5 Jul 2019 13:59:04 +0800
Dave Young  escreveu:

> On 07/05/19 at 11:43am, Alex Shi wrote:
> > 
> > 
> > 在 2019/6/28 下午8:30, Mauro Carvalho Chehab 写道:  
> > > The Kdump documentation describes procedures with admins use
> > > in order to solve issues on their systems.
> > > 
> > > Signed-off-by: Mauro Carvalho Chehab 
> > > ---
> > >  Documentation/admin-guide/bug-hunting.rst| 4 ++--
> > >  Documentation/admin-guide/index.rst  | 1 +
> > >  Documentation/{ => admin-guide}/kdump/gdbmacros.txt  | 0
> > >  Documentation/{ => admin-guide}/kdump/index.rst  | 1 -
> > >  Documentation/{ => admin-guide}/kdump/kdump.rst  | 0
> > >  Documentation/{ => admin-guide}/kdump/vmcoreinfo.rst | 0  
> > 
> > I am not sure if it's convenience for people to have more levels in docs.
> > 
> > But I guess, move archs into a Documentation/arch/ dir should be fine. like 
> > Documentation/arch/{x86,arm,arm64,ia64,m68k,s390,powerpc,...}  
> 
> Alex, moving kdump to admin-guide sounds reasonable to me.  I also agree
> with you for those arch dependent files can be moved to
> Documentation/arch/, maybe you are talking about some other patches in
> the series for the arch/? 

Alex,

It makes sense for me to have a Documentation/arch directory, and place
the arch-specific docs over there.

There's actually a technical advantage on doing that: Sphinx is dumb
with regards to PDF/LaTeX output: it requires all top documents to be
listed at Documentation/conf.py, under this var:

latex_documents = [
...
]

As it creates one runtime Makefile at Documentation/output per listed
document there. So, the more we group such documents, the less merge
conflicts we'll have at Documentation/conf.py.

Btw, there's a [TECH TOPIC] proposal for KS/2019 meant to discuss 
Documentation.

I suspect we could discuss the pros/cons of doing such change there.

My personal view is that we should keep the Documentation/ root dir as
clean as possible as a long term goal.

On the other hand, it makes the path bigger and harder to rename.

On a side note, last time we discussed documentation at KS I remember
I proposed to shortcut "Documentation/" to just "docs/". The consensus
on that time were to keep the big name. I still think that a shorter
one could help people to remind where documentation will be located.

Thanks,
Mauro


[PATCH 18/39] docs: admin-guide: add kdump documentation into it

2019-06-28 Thread Mauro Carvalho Chehab
The Kdump documentation describes procedures with admins use
in order to solve issues on their systems.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/admin-guide/bug-hunting.rst| 4 ++--
 Documentation/admin-guide/index.rst  | 1 +
 Documentation/{ => admin-guide}/kdump/gdbmacros.txt  | 0
 Documentation/{ => admin-guide}/kdump/index.rst  | 1 -
 Documentation/{ => admin-guide}/kdump/kdump.rst  | 0
 Documentation/{ => admin-guide}/kdump/vmcoreinfo.rst | 0
 Documentation/admin-guide/kernel-parameters.txt  | 6 +++---
 Documentation/powerpc/firmware-assisted-dump.rst | 2 +-
 Documentation/translations/zh_CN/oops-tracing.txt| 4 ++--
 Documentation/watchdog/hpwdt.rst | 2 +-
 MAINTAINERS  | 2 +-
 arch/arm/Kconfig | 2 +-
 arch/arm64/Kconfig   | 2 +-
 arch/sh/Kconfig  | 2 +-
 arch/x86/Kconfig | 4 ++--
 15 files changed, 16 insertions(+), 16 deletions(-)
 rename Documentation/{ => admin-guide}/kdump/gdbmacros.txt (100%)
 rename Documentation/{ => admin-guide}/kdump/index.rst (97%)
 rename Documentation/{ => admin-guide}/kdump/kdump.rst (100%)
 rename Documentation/{ => admin-guide}/kdump/vmcoreinfo.rst (100%)

diff --git a/Documentation/admin-guide/bug-hunting.rst 
b/Documentation/admin-guide/bug-hunting.rst
index b761aa2a51d2..44b8a4edd348 100644
--- a/Documentation/admin-guide/bug-hunting.rst
+++ b/Documentation/admin-guide/bug-hunting.rst
@@ -90,9 +90,9 @@ the disk is not available then you have three options:
 run a null modem to a second machine and capture the output there
 using your favourite communication program.  Minicom works well.
 
-(3) Use Kdump (see Documentation/kdump/kdump.rst),
+(3) Use Kdump (see Documentation/admin-guide/kdump/kdump.rst),
 extract the kernel ring buffer from old memory with using dmesg
-gdbmacro in Documentation/kdump/gdbmacros.txt.
+gdbmacro in Documentation/admin-guide/kdump/gdbmacros.txt.
 
 Finding the bug's location
 --
diff --git a/Documentation/admin-guide/index.rst 
b/Documentation/admin-guide/index.rst
index 9899b78dbe50..65e821a03aca 100644
--- a/Documentation/admin-guide/index.rst
+++ b/Documentation/admin-guide/index.rst
@@ -39,6 +39,7 @@ problems and bugs in particular.
ramoops
dynamic-debug-howto
init
+   kdump/index
perf/index
 
 This is the beginning of a section with information of interest to
diff --git a/Documentation/kdump/gdbmacros.txt 
b/Documentation/admin-guide/kdump/gdbmacros.txt
similarity index 100%
rename from Documentation/kdump/gdbmacros.txt
rename to Documentation/admin-guide/kdump/gdbmacros.txt
diff --git a/Documentation/kdump/index.rst 
b/Documentation/admin-guide/kdump/index.rst
similarity index 97%
rename from Documentation/kdump/index.rst
rename to Documentation/admin-guide/kdump/index.rst
index 2b17fcf6867a..8e2ebd0383cd 100644
--- a/Documentation/kdump/index.rst
+++ b/Documentation/admin-guide/kdump/index.rst
@@ -1,4 +1,3 @@
-:orphan:
 
 
 Documentation for Kdump - The kexec-based Crash Dumping Solution
diff --git a/Documentation/kdump/kdump.rst 
b/Documentation/admin-guide/kdump/kdump.rst
similarity index 100%
rename from Documentation/kdump/kdump.rst
rename to Documentation/admin-guide/kdump/kdump.rst
diff --git a/Documentation/kdump/vmcoreinfo.rst 
b/Documentation/admin-guide/kdump/vmcoreinfo.rst
similarity index 100%
rename from Documentation/kdump/vmcoreinfo.rst
rename to Documentation/admin-guide/kdump/vmcoreinfo.rst
diff --git a/Documentation/admin-guide/kernel-parameters.txt 
b/Documentation/admin-guide/kernel-parameters.txt
index e38b96d061f4..9b535c0e22f3 100644
--- a/Documentation/admin-guide/kernel-parameters.txt
+++ b/Documentation/admin-guide/kernel-parameters.txt
@@ -708,14 +708,14 @@
[KNL, x86_64] select a region under 4G first, and
fall back to reserve region above 4G when '@offset'
hasn't been specified.
-   See Documentation/kdump/kdump.rst for further details.
+   See Documentation/admin-guide/kdump/kdump.rst for 
further details.
 
crashkernel=range1:size1[,range2:size2,...][@offset]
[KNL] Same as above, but depends on the memory
in the running system. The syntax of range is
start-[end] where start and end are both
a memory unit (amount[KMG]). See also
-   Documentation/kdump/kdump.rst for an example.
+   Documentation/admin-guide/kdump/kdump.rst for an 
example.
 
crashkernel=size[KMG],high
[KNL, x86_64] range could be above 4G. Allow k

[PATCH 13/39] docs: add arch doc directories to the index

2019-06-28 Thread Mauro Carvalho Chehab
Now that several arch documents were converted to ReST,
add their indexes to Documentation/index.rst and remove the
:orphan:  from them.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/arm/index.rst |  2 --
 Documentation/arm64/index.rst   |  2 --
 Documentation/ia64/index.rst|  2 --
 Documentation/index.rst | 10 ++
 Documentation/m68k/index.rst|  2 +-
 Documentation/powerpc/index.rst |  2 +-
 Documentation/riscv/index.rst   |  2 --
 Documentation/s390/index.rst|  2 --
 Documentation/sparc/index.rst   |  2 --
 Documentation/xtensa/index.rst  |  2 +-
 10 files changed, 13 insertions(+), 15 deletions(-)

diff --git a/Documentation/arm/index.rst b/Documentation/arm/index.rst
index bd316d1a1802..9c2f781f4685 100644
--- a/Documentation/arm/index.rst
+++ b/Documentation/arm/index.rst
@@ -1,5 +1,3 @@
-:orphan:
-
 
 ARM Architecture
 
diff --git a/Documentation/arm64/index.rst b/Documentation/arm64/index.rst
index 018b7836ecb7..96b696ba4e6c 100644
--- a/Documentation/arm64/index.rst
+++ b/Documentation/arm64/index.rst
@@ -1,5 +1,3 @@
-:orphan:
-
 ==
 ARM64 Architecture
 ==
diff --git a/Documentation/ia64/index.rst b/Documentation/ia64/index.rst
index a3e3052ad6e2..ef99475f672b 100644
--- a/Documentation/ia64/index.rst
+++ b/Documentation/ia64/index.rst
@@ -1,5 +1,3 @@
-:orphan:
-
 ==
 IA-64 Architecture
 ==
diff --git a/Documentation/index.rst b/Documentation/index.rst
index 95db26bf2899..f898def833f4 100644
--- a/Documentation/index.rst
+++ b/Documentation/index.rst
@@ -118,7 +118,17 @@ implementation.
:maxdepth: 2
 
sh/index
+   arm/index
+   arm64/index
+   ia64/index
+   m68k/index
+   powerpc/index
+   riscv/index
+   s390/index
+   sh/index
+   sparc/index
x86/index
+   xtensa/index
 
 Filesystem Documentation
 
diff --git a/Documentation/m68k/index.rst b/Documentation/m68k/index.rst
index f3273ec075c3..3a5ba7fe1703 100644
--- a/Documentation/m68k/index.rst
+++ b/Documentation/m68k/index.rst
@@ -1,4 +1,4 @@
-:orphan:
+.. SPDX-License-Identifier: GPL-2.0
 
 =
 m68k Architecture
diff --git a/Documentation/powerpc/index.rst b/Documentation/powerpc/index.rst
index 1ff17268db46..549b1cdd77ae 100644
--- a/Documentation/powerpc/index.rst
+++ b/Documentation/powerpc/index.rst
@@ -1,4 +1,4 @@
-:orphan:
+.. SPDX-License-Identifier: GPL-2.0
 
 ===
 powerpc
diff --git a/Documentation/riscv/index.rst b/Documentation/riscv/index.rst
index c4b906d9b5a7..e3ca0922a8c2 100644
--- a/Documentation/riscv/index.rst
+++ b/Documentation/riscv/index.rst
@@ -1,5 +1,3 @@
-:orphan:
-
 ===
 RISC-V architecture
 ===
diff --git a/Documentation/s390/index.rst b/Documentation/s390/index.rst
index 1a914da2a07b..4602312909d3 100644
--- a/Documentation/s390/index.rst
+++ b/Documentation/s390/index.rst
@@ -1,5 +1,3 @@
-:orphan:
-
 =
 s390 Architecture
 =
diff --git a/Documentation/sparc/index.rst b/Documentation/sparc/index.rst
index 91f7d6643dd5..71cff621f243 100644
--- a/Documentation/sparc/index.rst
+++ b/Documentation/sparc/index.rst
@@ -1,5 +1,3 @@
-:orphan:
-
 ==
 Sparc Architecture
 ==
diff --git a/Documentation/xtensa/index.rst b/Documentation/xtensa/index.rst
index 5a24e365e35f..52fa04eb39a3 100644
--- a/Documentation/xtensa/index.rst
+++ b/Documentation/xtensa/index.rst
@@ -1,4 +1,4 @@
-:orphan:
+.. SPDX-License-Identifier: GPL-2.0
 
 ===
 Xtensa Architecture
-- 
2.21.0



[PATCH 32/39] docs: serial: move it to the driver-api

2019-06-28 Thread Mauro Carvalho Chehab
The contents of this directory is mostly driver-api stuff.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/driver-api/index.rst   | 1 +
 Documentation/{ => driver-api}/serial/cyclades_z.rst | 0
 Documentation/{ => driver-api}/serial/driver.rst | 2 +-
 Documentation/{ => driver-api}/serial/index.rst  | 2 +-
 Documentation/{ => driver-api}/serial/moxa-smartio.rst   | 0
 Documentation/{ => driver-api}/serial/n_gsm.rst  | 0
 Documentation/{ => driver-api}/serial/rocket.rst | 0
 Documentation/{ => driver-api}/serial/serial-iso7816.rst | 0
 Documentation/{ => driver-api}/serial/serial-rs485.rst   | 0
 Documentation/{ => driver-api}/serial/tty.rst| 0
 MAINTAINERS  | 6 +++---
 drivers/tty/Kconfig  | 4 ++--
 drivers/tty/serial/ucc_uart.c| 2 +-
 include/linux/serial_core.h  | 2 +-
 14 files changed, 10 insertions(+), 9 deletions(-)
 rename Documentation/{ => driver-api}/serial/cyclades_z.rst (100%)
 rename Documentation/{ => driver-api}/serial/driver.rst (99%)
 rename Documentation/{ => driver-api}/serial/index.rst (90%)
 rename Documentation/{ => driver-api}/serial/moxa-smartio.rst (100%)
 rename Documentation/{ => driver-api}/serial/n_gsm.rst (100%)
 rename Documentation/{ => driver-api}/serial/rocket.rst (100%)
 rename Documentation/{ => driver-api}/serial/serial-iso7816.rst (100%)
 rename Documentation/{ => driver-api}/serial/serial-rs485.rst (100%)
 rename Documentation/{ => driver-api}/serial/tty.rst (100%)

diff --git a/Documentation/driver-api/index.rst 
b/Documentation/driver-api/index.rst
index f44a3140f95d..d6f532c8d824 100644
--- a/Documentation/driver-api/index.rst
+++ b/Documentation/driver-api/index.rst
@@ -88,6 +88,7 @@ available subsections can be seen below.
pti_intel_mid
pwm
rfkill
+   serial/index
sgi-ioc4
sm501
smsc_ece1099
diff --git a/Documentation/serial/cyclades_z.rst 
b/Documentation/driver-api/serial/cyclades_z.rst
similarity index 100%
rename from Documentation/serial/cyclades_z.rst
rename to Documentation/driver-api/serial/cyclades_z.rst
diff --git a/Documentation/serial/driver.rst 
b/Documentation/driver-api/serial/driver.rst
similarity index 99%
rename from Documentation/serial/driver.rst
rename to Documentation/driver-api/serial/driver.rst
index 4537119bf624..31bd4e16fb1f 100644
--- a/Documentation/serial/driver.rst
+++ b/Documentation/driver-api/serial/driver.rst
@@ -311,7 +311,7 @@ hardware.
This call must not sleep
 
   set_ldisc(port,termios)
-   Notifier for discipline change. See Documentation/serial/tty.rst.
+   Notifier for discipline change. See 
Documentation/driver-api/serial/tty.rst.
 
Locking: caller holds tty_port->mutex
 
diff --git a/Documentation/serial/index.rst 
b/Documentation/driver-api/serial/index.rst
similarity index 90%
rename from Documentation/serial/index.rst
rename to Documentation/driver-api/serial/index.rst
index d0ba22ea23bf..33ad10d05b26 100644
--- a/Documentation/serial/index.rst
+++ b/Documentation/driver-api/serial/index.rst
@@ -1,4 +1,4 @@
-:orphan:
+.. SPDX-License-Identifier: GPL-2.0
 
 ==
 Support for Serial devices
diff --git a/Documentation/serial/moxa-smartio.rst 
b/Documentation/driver-api/serial/moxa-smartio.rst
similarity index 100%
rename from Documentation/serial/moxa-smartio.rst
rename to Documentation/driver-api/serial/moxa-smartio.rst
diff --git a/Documentation/serial/n_gsm.rst 
b/Documentation/driver-api/serial/n_gsm.rst
similarity index 100%
rename from Documentation/serial/n_gsm.rst
rename to Documentation/driver-api/serial/n_gsm.rst
diff --git a/Documentation/serial/rocket.rst 
b/Documentation/driver-api/serial/rocket.rst
similarity index 100%
rename from Documentation/serial/rocket.rst
rename to Documentation/driver-api/serial/rocket.rst
diff --git a/Documentation/serial/serial-iso7816.rst 
b/Documentation/driver-api/serial/serial-iso7816.rst
similarity index 100%
rename from Documentation/serial/serial-iso7816.rst
rename to Documentation/driver-api/serial/serial-iso7816.rst
diff --git a/Documentation/serial/serial-rs485.rst 
b/Documentation/driver-api/serial/serial-rs485.rst
similarity index 100%
rename from Documentation/serial/serial-rs485.rst
rename to Documentation/driver-api/serial/serial-rs485.rst
diff --git a/Documentation/serial/tty.rst 
b/Documentation/driver-api/serial/tty.rst
similarity index 100%
rename from Documentation/serial/tty.rst
rename to Documentation/driver-api/serial/tty.rst
diff --git a/MAINTAINERS b/MAINTAINERS
index 055db86fdd77..856db8015edd 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -10723,7 +10723,7 @@ F:  include/uapi/linux/meye.h
 MOXA SMARTIO/INDUSTIO/INTELLIO SERIAL CARD
 M: Jiri Slaby 
 S: Maintained
-F: Documentation/serial/moxa

[PATCH 22/39] docs: ocxl.rst: add it to the uAPI book

2019-06-28 Thread Mauro Carvalho Chehab
The content of this file is user-faced.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/{ => userspace-api}/accelerators/ocxl.rst | 2 --
 Documentation/userspace-api/index.rst   | 1 +
 MAINTAINERS | 2 +-
 3 files changed, 2 insertions(+), 3 deletions(-)
 rename Documentation/{ => userspace-api}/accelerators/ocxl.rst (99%)

diff --git a/Documentation/accelerators/ocxl.rst 
b/Documentation/userspace-api/accelerators/ocxl.rst
similarity index 99%
rename from Documentation/accelerators/ocxl.rst
rename to Documentation/userspace-api/accelerators/ocxl.rst
index b1cea19a90f5..14cefc020e2d 100644
--- a/Documentation/accelerators/ocxl.rst
+++ b/Documentation/userspace-api/accelerators/ocxl.rst
@@ -1,5 +1,3 @@
-:orphan:
-
 
 OpenCAPI (Open Coherent Accelerator Processor Interface)
 
diff --git a/Documentation/userspace-api/index.rst 
b/Documentation/userspace-api/index.rst
index a3233da7fa88..ad494da40009 100644
--- a/Documentation/userspace-api/index.rst
+++ b/Documentation/userspace-api/index.rst
@@ -20,6 +20,7 @@ place where this information is gathered.
seccomp_filter
unshare
spec_ctrl
+   accelerators/ocxl
 
 .. only::  subproject and html
 
diff --git a/MAINTAINERS b/MAINTAINERS
index 29d1498ad39d..f723371dccd0 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -11483,7 +11483,7 @@ F:  arch/powerpc/include/asm/pnv-ocxl.h
 F: drivers/misc/ocxl/
 F: include/misc/ocxl*
 F: include/uapi/misc/ocxl.h
-F: Documentation/accelerators/ocxl.rst
+F: Documentation/userspace-api/accelerators/ocxl.rst
 
 OMAP AUDIO SUPPORT
 M: Peter Ujfalusi 
-- 
2.21.0



[PATCH 05/43] docs: powerpc: convert docs to ReST and rename to *.rst

2019-06-28 Thread Mauro Carvalho Chehab
Convert docs to ReST and add them to the arch-specific
book.

The conversion here was trivial, as almost every file there
was already using an elegant format close to ReST standard.

The changes were mostly to mark literal blocks and add a few
missing section title identifiers.

One note with regards to "--": on Sphinx, this can't be used
to identify a list, as it will format it badly. This can be
used, however, to identify a long hyphen - and "---" is an
even longer one.

At its new index.rst, let's add a :orphan: while this is not linked to
the main index.rst file, in order to avoid build warnings.

Signed-off-by: Mauro Carvalho Chehab 
Acked-by: Andrew Donnellan  # cxl
---
 Documentation/PCI/pci-error-recovery.rst  |  23 ++-
 .../{bootwrapper.txt => bootwrapper.rst}  |  28 +++-
 .../{cpu_families.txt => cpu_families.rst}|  23 +--
 .../{cpu_features.txt => cpu_features.rst}|   6 +-
 Documentation/powerpc/{cxl.txt => cxl.rst}|  46 --
 .../powerpc/{cxlflash.txt => cxlflash.rst}|  10 +-
 .../{DAWR-POWER9.txt => dawr-power9.rst}  |  15 +-
 Documentation/powerpc/{dscr.txt => dscr.rst}  |  18 +-
 ...ecovery.txt => eeh-pci-error-recovery.rst} | 108 ++--
 ...ed-dump.txt => firmware-assisted-dump.rst} | 117 +++--
 Documentation/powerpc/{hvcs.txt => hvcs.rst}  | 108 ++--
 Documentation/powerpc/index.rst   |  34 
 Documentation/powerpc/isa-versions.rst|  15 +-
 .../powerpc/{mpc52xx.txt => mpc52xx.rst}  |  12 +-
 ...nv.txt => pci_iov_resource_on_powernv.rst} |  15 +-
 .../powerpc/{pmu-ebb.txt => pmu-ebb.rst}  |   1 +
 Documentation/powerpc/ptrace.rst  | 156 ++
 Documentation/powerpc/ptrace.txt  | 151 -
 .../{qe_firmware.txt => qe_firmware.rst}  |  37 +++--
 .../{syscall64-abi.txt => syscall64-abi.rst}  |  29 ++--
 ...al_memory.txt => transactional_memory.rst} |  45 ++---
 MAINTAINERS   |   6 +-
 arch/powerpc/kernel/exceptions-64s.S  |   2 +-
 drivers/soc/fsl/qe/qe.c   |   2 +-
 drivers/tty/hvc/hvcs.c|   2 +-
 include/soc/fsl/qe/qe.h   |   2 +-
 26 files changed, 584 insertions(+), 427 deletions(-)
 rename Documentation/powerpc/{bootwrapper.txt => bootwrapper.rst} (93%)
 rename Documentation/powerpc/{cpu_families.txt => cpu_families.rst} (95%)
 rename Documentation/powerpc/{cpu_features.txt => cpu_features.rst} (97%)
 rename Documentation/powerpc/{cxl.txt => cxl.rst} (95%)
 rename Documentation/powerpc/{cxlflash.txt => cxlflash.rst} (98%)
 rename Documentation/powerpc/{DAWR-POWER9.txt => dawr-power9.rst} (95%)
 rename Documentation/powerpc/{dscr.txt => dscr.rst} (91%)
 rename Documentation/powerpc/{eeh-pci-error-recovery.txt => 
eeh-pci-error-recovery.rst} (82%)
 rename Documentation/powerpc/{firmware-assisted-dump.txt => 
firmware-assisted-dump.rst} (80%)
 rename Documentation/powerpc/{hvcs.txt => hvcs.rst} (91%)
 create mode 100644 Documentation/powerpc/index.rst
 rename Documentation/powerpc/{mpc52xx.txt => mpc52xx.rst} (91%)
 rename Documentation/powerpc/{pci_iov_resource_on_powernv.txt => 
pci_iov_resource_on_powernv.rst} (97%)
 rename Documentation/powerpc/{pmu-ebb.txt => pmu-ebb.rst} (99%)
 create mode 100644 Documentation/powerpc/ptrace.rst
 delete mode 100644 Documentation/powerpc/ptrace.txt
 rename Documentation/powerpc/{qe_firmware.txt => qe_firmware.rst} (95%)
 rename Documentation/powerpc/{syscall64-abi.txt => syscall64-abi.rst} (82%)
 rename Documentation/powerpc/{transactional_memory.txt => 
transactional_memory.rst} (93%)

diff --git a/Documentation/PCI/pci-error-recovery.rst 
b/Documentation/PCI/pci-error-recovery.rst
index 83db42092935..acc21ecca322 100644
--- a/Documentation/PCI/pci-error-recovery.rst
+++ b/Documentation/PCI/pci-error-recovery.rst
@@ -403,7 +403,7 @@ That is, the recovery API only requires that:
 .. note::
 
Implementation details for the powerpc platform are discussed in
-   the file Documentation/powerpc/eeh-pci-error-recovery.txt
+   the file Documentation/powerpc/eeh-pci-error-recovery.rst
 
As of this writing, there is a growing list of device drivers with
patches implementing error recovery. Not all of these patches are in
@@ -422,3 +422,24 @@ That is, the recovery API only requires that:
- drivers/net/cxgb3
- drivers/net/s2io.c
- drivers/net/qlge
+
+>>> As of this writing, there is a growing list of device drivers with
+>>> patches implementing error recovery. Not all of these patches are in
+>>> mainline yet. These may be used as "examples":
+>>>
+>>> drivers/scsi/ipr
+>>> drivers/scsi/sym53c8xx_2
+>>> drivers/scsi/qla2xxx
+>>> drivers/scsi/lpfc
+>>> drivers/next/bnx2.c
+>>> drivers/nex

[PATCH v1 22/22] admin-guide: add kdump documentation into it

2019-06-18 Thread Mauro Carvalho Chehab
The Kdump documentation describes procedures with admins use
in order to solve issues on their systems.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/admin-guide/bug-hunting.rst| 4 ++--
 Documentation/admin-guide/index.rst  | 1 +
 Documentation/{ => admin-guide}/kdump/gdbmacros.txt  | 0
 Documentation/{ => admin-guide}/kdump/index.rst  | 1 -
 Documentation/{ => admin-guide}/kdump/kdump.rst  | 0
 Documentation/{ => admin-guide}/kdump/vmcoreinfo.rst | 0
 Documentation/admin-guide/kernel-parameters.txt  | 6 +++---
 Documentation/powerpc/firmware-assisted-dump.rst | 2 +-
 Documentation/translations/zh_CN/oops-tracing.txt| 4 ++--
 Documentation/watchdog/hpwdt.rst | 2 +-
 MAINTAINERS  | 2 +-
 arch/arm/Kconfig | 2 +-
 arch/arm64/Kconfig   | 2 +-
 arch/sh/Kconfig  | 2 +-
 arch/x86/Kconfig | 4 ++--
 15 files changed, 16 insertions(+), 16 deletions(-)
 rename Documentation/{ => admin-guide}/kdump/gdbmacros.txt (100%)
 rename Documentation/{ => admin-guide}/kdump/index.rst (97%)
 rename Documentation/{ => admin-guide}/kdump/kdump.rst (100%)
 rename Documentation/{ => admin-guide}/kdump/vmcoreinfo.rst (100%)

diff --git a/Documentation/admin-guide/bug-hunting.rst 
b/Documentation/admin-guide/bug-hunting.rst
index b761aa2a51d2..44b8a4edd348 100644
--- a/Documentation/admin-guide/bug-hunting.rst
+++ b/Documentation/admin-guide/bug-hunting.rst
@@ -90,9 +90,9 @@ the disk is not available then you have three options:
 run a null modem to a second machine and capture the output there
 using your favourite communication program.  Minicom works well.
 
-(3) Use Kdump (see Documentation/kdump/kdump.rst),
+(3) Use Kdump (see Documentation/admin-guide/kdump/kdump.rst),
 extract the kernel ring buffer from old memory with using dmesg
-gdbmacro in Documentation/kdump/gdbmacros.txt.
+gdbmacro in Documentation/admin-guide/kdump/gdbmacros.txt.
 
 Finding the bug's location
 --
diff --git a/Documentation/admin-guide/index.rst 
b/Documentation/admin-guide/index.rst
index e4f0cb2a02bd..9f6820a7e8f8 100644
--- a/Documentation/admin-guide/index.rst
+++ b/Documentation/admin-guide/index.rst
@@ -39,6 +39,7 @@ problems and bugs in particular.
ramoops
dynamic-debug-howto
init
+   kdump/index
 
 This is the beginning of a section with information of interest to
 application developers.  Documents covering various aspects of the kernel
diff --git a/Documentation/kdump/gdbmacros.txt 
b/Documentation/admin-guide/kdump/gdbmacros.txt
similarity index 100%
rename from Documentation/kdump/gdbmacros.txt
rename to Documentation/admin-guide/kdump/gdbmacros.txt
diff --git a/Documentation/kdump/index.rst 
b/Documentation/admin-guide/kdump/index.rst
similarity index 97%
rename from Documentation/kdump/index.rst
rename to Documentation/admin-guide/kdump/index.rst
index 2b17fcf6867a..8e2ebd0383cd 100644
--- a/Documentation/kdump/index.rst
+++ b/Documentation/admin-guide/kdump/index.rst
@@ -1,4 +1,3 @@
-:orphan:
 
 
 Documentation for Kdump - The kexec-based Crash Dumping Solution
diff --git a/Documentation/kdump/kdump.rst 
b/Documentation/admin-guide/kdump/kdump.rst
similarity index 100%
rename from Documentation/kdump/kdump.rst
rename to Documentation/admin-guide/kdump/kdump.rst
diff --git a/Documentation/kdump/vmcoreinfo.rst 
b/Documentation/admin-guide/kdump/vmcoreinfo.rst
similarity index 100%
rename from Documentation/kdump/vmcoreinfo.rst
rename to Documentation/admin-guide/kdump/vmcoreinfo.rst
diff --git a/Documentation/admin-guide/kernel-parameters.txt 
b/Documentation/admin-guide/kernel-parameters.txt
index 69a9e2e66dfb..1f3fc445c78d 100644
--- a/Documentation/admin-guide/kernel-parameters.txt
+++ b/Documentation/admin-guide/kernel-parameters.txt
@@ -708,14 +708,14 @@
[KNL, x86_64] select a region under 4G first, and
fall back to reserve region above 4G when '@offset'
hasn't been specified.
-   See Documentation/kdump/kdump.rst for further details.
+   See Documentation/admin-guide/kdump/kdump.rst for 
further details.
 
crashkernel=range1:size1[,range2:size2,...][@offset]
[KNL] Same as above, but depends on the memory
in the running system. The syntax of range is
start-[end] where start and end are both
a memory unit (amount[KMG]). See also
-   Documentation/kdump/kdump.rst for an example.
+   Documentation/admin-guide/kdump/kdump.rst for an 
example.
 
crashkernel=size[KMG],high

[PATCH 01/14] ABI: fix some syntax issues at the ABI database

2019-06-13 Thread Mauro Carvalho Chehab
From: Mauro Carvalho Chehab 

On those three files, the ABI representation described at
README are violated.

- at sysfs-bus-iio-proximity-as3935:
a ':' character is missing after "What"

- at sysfs-class-devfreq:
there's a typo at Description

- at sysfs-class-cxl, it is using the ":" character at a
file preamble, causing it to be misinterpreted as a
tag.

- On the other files, instead of "What", they use "Where".

Signed-off-by: Mauro Carvalho Chehab 
Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/ABI/testing/pstore  |  2 +-
 .../sysfs-bus-event_source-devices-format |  2 +-
 .../ABI/testing/sysfs-bus-i2c-devices-hm6352  |  6 ++---
 .../ABI/testing/sysfs-bus-iio-distance-srf08  |  4 ++--
 .../testing/sysfs-bus-iio-proximity-as3935|  4 ++--
 .../ABI/testing/sysfs-bus-pci-devices-cciss   | 22 +--
 .../testing/sysfs-bus-usb-devices-usbsevseg   | 12 +-
 Documentation/ABI/testing/sysfs-class-cxl |  6 ++---
 Documentation/ABI/testing/sysfs-class-devfreq |  2 +-
 .../ABI/testing/sysfs-class-powercap  |  2 +-
 Documentation/ABI/testing/sysfs-kernel-fscaps |  2 +-
 .../ABI/testing/sysfs-kernel-vmcoreinfo   |  2 +-
 12 files changed, 33 insertions(+), 33 deletions(-)

diff --git a/Documentation/ABI/testing/pstore b/Documentation/ABI/testing/pstore
index 5fca9f5e10a3..8d6e48f4e8ef 100644
--- a/Documentation/ABI/testing/pstore
+++ b/Documentation/ABI/testing/pstore
@@ -1,4 +1,4 @@
-Where: /sys/fs/pstore/... (or /dev/pstore/...)
+What:  /sys/fs/pstore/... (or /dev/pstore/...)
 Date:  March 2011
 Kernel Version: 2.6.39
 Contact:   tony.l...@intel.com
diff --git a/Documentation/ABI/testing/sysfs-bus-event_source-devices-format 
b/Documentation/ABI/testing/sysfs-bus-event_source-devices-format
index 77f47ff5ee02..b6f8748e0200 100644
--- a/Documentation/ABI/testing/sysfs-bus-event_source-devices-format
+++ b/Documentation/ABI/testing/sysfs-bus-event_source-devices-format
@@ -1,4 +1,4 @@
-Where: /sys/bus/event_source/devices//format
+What:  /sys/bus/event_source/devices//format
 Date:  January 2012
 Kernel Version: 3.3
 Contact:   Jiri Olsa 
diff --git a/Documentation/ABI/testing/sysfs-bus-i2c-devices-hm6352 
b/Documentation/ABI/testing/sysfs-bus-i2c-devices-hm6352
index feb2e4a87075..29bd447e50a0 100644
--- a/Documentation/ABI/testing/sysfs-bus-i2c-devices-hm6352
+++ b/Documentation/ABI/testing/sysfs-bus-i2c-devices-hm6352
@@ -1,18 +1,18 @@
-Where: /sys/bus/i2c/devices/.../heading0_input
+What:  /sys/bus/i2c/devices/.../heading0_input
 Date:  April 2010
 Kernel Version: 2.6.36?
 Contact:   alan@intel.com
 Description:   Reports the current heading from the compass as a floating
point value in degrees.
 
-Where: /sys/bus/i2c/devices/.../power_state
+What:  /sys/bus/i2c/devices/.../power_state
 Date:  April 2010
 Kernel Version: 2.6.36?
 Contact:   alan@intel.com
 Description:   Sets the power state of the device. 0 sets the device into
sleep mode, 1 wakes it up.
 
-Where: /sys/bus/i2c/devices/.../calibration
+What:  /sys/bus/i2c/devices/.../calibration
 Date:  April 2010
 Kernel Version: 2.6.36?
 Contact:   alan@intel.com
diff --git a/Documentation/ABI/testing/sysfs-bus-iio-distance-srf08 
b/Documentation/ABI/testing/sysfs-bus-iio-distance-srf08
index 0a1ca1487fa9..a133fd8d081a 100644
--- a/Documentation/ABI/testing/sysfs-bus-iio-distance-srf08
+++ b/Documentation/ABI/testing/sysfs-bus-iio-distance-srf08
@@ -1,4 +1,4 @@
-What   /sys/bus/iio/devices/iio:deviceX/sensor_sensitivity
+What:  /sys/bus/iio/devices/iio:deviceX/sensor_sensitivity
 Date:  January 2017
 KernelVersion: 4.11
 Contact:   linux-...@vger.kernel.org
@@ -6,7 +6,7 @@ Description:
Show or set the gain boost of the amp, from 0-31 range.
default 31
 
-What   /sys/bus/iio/devices/iio:deviceX/sensor_max_range
+What:  /sys/bus/iio/devices/iio:deviceX/sensor_max_range
 Date:  January 2017
 KernelVersion: 4.11
 Contact:   linux-...@vger.kernel.org
diff --git a/Documentation/ABI/testing/sysfs-bus-iio-proximity-as3935 
b/Documentation/ABI/testing/sysfs-bus-iio-proximity-as3935
index 9a17ab5036a4..c59d95346341 100644
--- a/Documentation/ABI/testing/sysfs-bus-iio-proximity-as3935
+++ b/Documentation/ABI/testing/sysfs-bus-iio-proximity-as3935
@@ -1,4 +1,4 @@
-What   /sys/bus/iio/devices/iio:deviceX/in_proximity_input
+What:  /sys/bus/iio/devices/iio:deviceX/in_proximity_input
 Date:  March 2014
 KernelVersion: 3.15
 Contact:   Matt Ranostay 
@@ -6,7 +6,7 @@ Description:
Get the current distance in meters of storm (1km steps)
1000-4 = distance in meters
 
-What   /sys/bus/iio/devi

[PATCH 00/14] Add support to generate ABI documentation at admin-guide

2019-06-13 Thread Mauro Carvalho Chehab
Greg,

As promised, I'm resending the patch series with adds the Kernel ABI to
Documentation/admin-guide.

Those patches are basically the version 3 patchset I sent back in 2017,
rebased on the top of linux-next (next-20190613), and with some fixes
in order for it to work.

- The 4 initial patches to fix some ABI descriptions that are violating 
  the syntax described at Documentation/ABI/README;

- The next 6 patches are the ones originally written in 2017 with a
  script with parses the ABI files;

- The 11th patch is a new one: it relaxes a little bit the parser in 
  order to parse file headers that contains colons on it;

- The 12th patch adds the new script to the documentation build
  system, together with a new python Sphinx extension with calls it;

- The 13th patch fixes the python script when running with newer
  Sphinx versions (1.7 and upper);

- The final patch fixes an UTF-8 trouble. I noticed it only with Sphinx
  1.4, but it could affect other versions too. So, I ended by changing
  the UTF-8 encoding logit to work version-independent, just like
  what happens with kerneldoc.py extension.

Mauro Carvalho Chehab (14):
  ABI: fix some syntax issues at the ABI database
  ABI: sysfs-driver-hid: the "What" field doesn't parse fine
  ABI: sysfs-class-uwb_rc: remove a duplicated incomplete entry
  ABI: better identificate tables
  scripts: add an script to parse the ABI files
  scripts/get_abi.pl: parse files with text at beginning
  scripts/get_abi.pl: avoid use literal blocks when not needed
  scripts/get_abi.pl: split label naming from xref logic
  scripts/get_abi.pl: add support for searching for ABI symbols
  scripts/get_abi.pl: represent what in tables
  scripts/get_abi.pl: fix parse issues with some files
  doc-rst: add ABI documentation to the admin-guide book
  sphinx/kernel_abi.py: make it compatible with Sphinx 1.7+
  docs: sphinx/kernel_abi.py: fix UTF-8 support

 .../ABI/obsolete/sysfs-driver-hid-roccat-pyra |   2 +-
 Documentation/ABI/testing/pstore  |   2 +-
 .../sysfs-bus-event_source-devices-format |   2 +-
 .../ABI/testing/sysfs-bus-i2c-devices-hm6352  |   6 +-
 .../ABI/testing/sysfs-bus-iio-distance-srf08  |   4 +-
 .../testing/sysfs-bus-iio-proximity-as3935|   4 +-
 .../ABI/testing/sysfs-bus-pci-devices-cciss   |  22 +-
 .../testing/sysfs-bus-usb-devices-usbsevseg   |  12 +-
 .../sysfs-class-backlight-driver-lm3533   |   6 +-
 Documentation/ABI/testing/sysfs-class-cxl |   6 +-
 Documentation/ABI/testing/sysfs-class-devfreq |   2 +-
 .../ABI/testing/sysfs-class-led-driver-lm3533 |   8 +-
 .../ABI/testing/sysfs-class-leds-gt683r   |   4 +-
 .../ABI/testing/sysfs-class-powercap  |   2 +-
 Documentation/ABI/testing/sysfs-class-uwb_rc  |   6 -
 Documentation/ABI/testing/sysfs-driver-hid|  12 +-
 .../ABI/testing/sysfs-driver-hid-roccat-kone  |   2 +-
 Documentation/ABI/testing/sysfs-kernel-fscaps |   2 +-
 .../ABI/testing/sysfs-kernel-vmcoreinfo   |   2 +-
 Documentation/admin-guide/abi-obsolete.rst|  10 +
 Documentation/admin-guide/abi-removed.rst |   4 +
 Documentation/admin-guide/abi-stable.rst  |  13 +
 Documentation/admin-guide/abi-testing.rst |  19 +
 Documentation/admin-guide/abi.rst |  11 +
 Documentation/admin-guide/index.rst   |   1 +
 Documentation/conf.py |   2 +-
 Documentation/sphinx/kernel_abi.py| 172 +++
 scripts/get_abi.pl| 450 ++
 28 files changed, 731 insertions(+), 57 deletions(-)
 create mode 100644 Documentation/admin-guide/abi-obsolete.rst
 create mode 100644 Documentation/admin-guide/abi-removed.rst
 create mode 100644 Documentation/admin-guide/abi-stable.rst
 create mode 100644 Documentation/admin-guide/abi-testing.rst
 create mode 100644 Documentation/admin-guide/abi.rst
 create mode 100644 Documentation/sphinx/kernel_abi.py
 create mode 100755 scripts/get_abi.pl

-- 
2.21.0




[PATCH v4 12/28] docs: kbuild: convert docs to ReST and rename to *.rst

2019-06-12 Thread Mauro Carvalho Chehab
The kbuild documentation clearly shows that the documents
there are written at different times: some use markdown,
some use their own peculiar logic to split sections.

Convert everything to ReST without affecting too much
the author's style and avoiding adding uneeded markups.

The conversion is actually:
  - add blank lines and identation in order to identify paragraphs;
  - fix tables markups;
  - add some lists markups;
  - mark literal blocks;
  - adjust title markups.

At its new index.rst, let's add a :orphan: while this is not linked to
the main index.rst file, in order to avoid build warnings.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/admin-guide/README.rst  |   2 +-
 ...eaders_install.txt => headers_install.rst} |   5 +-
 Documentation/kbuild/index.rst|  27 +
 Documentation/kbuild/issues.rst   |  11 +
 .../kbuild/{kbuild.txt => kbuild.rst} | 119 ++--
 ...nfig-language.txt => kconfig-language.rst} | 232 
 ...anguage.txt => kconfig-macro-language.rst} |  37 +-
 .../kbuild/{kconfig.txt => kconfig.rst}   | 136 +++--
 .../kbuild/{makefiles.txt => makefiles.rst}   | 530 +++---
 .../kbuild/{modules.txt => modules.rst}   | 168 +++---
 Documentation/kernel-hacking/hacking.rst  |   4 +-
 Documentation/process/coding-style.rst|   2 +-
 Documentation/process/submit-checklist.rst|   2 +-
 .../it_IT/kernel-hacking/hacking.rst  |   4 +-
 .../it_IT/process/coding-style.rst|   2 +-
 .../it_IT/process/submit-checklist.rst|   2 +-
 .../zh_CN/process/coding-style.rst|   2 +-
 .../zh_CN/process/submit-checklist.rst|   2 +-
 Kconfig   |   2 +-
 arch/arc/plat-eznps/Kconfig   |   2 +-
 arch/c6x/Kconfig  |   2 +-
 arch/microblaze/Kconfig.debug |   2 +-
 arch/microblaze/Kconfig.platform  |   2 +-
 arch/nds32/Kconfig|   2 +-
 arch/openrisc/Kconfig |   2 +-
 arch/powerpc/sysdev/Kconfig   |   2 +-
 arch/riscv/Kconfig|   2 +-
 drivers/auxdisplay/Kconfig|   2 +-
 drivers/firmware/Kconfig  |   2 +-
 drivers/mtd/devices/Kconfig   |   2 +-
 drivers/net/ethernet/smsc/Kconfig |   6 +-
 drivers/net/wireless/intel/iwlegacy/Kconfig   |   4 +-
 drivers/net/wireless/intel/iwlwifi/Kconfig|   2 +-
 drivers/parport/Kconfig   |   2 +-
 drivers/scsi/Kconfig  |   4 +-
 drivers/staging/sm750fb/Kconfig   |   2 +-
 drivers/usb/misc/Kconfig  |   4 +-
 drivers/video/fbdev/Kconfig   |  14 +-
 net/bridge/netfilter/Kconfig  |   2 +-
 net/ipv4/netfilter/Kconfig|   2 +-
 net/ipv6/netfilter/Kconfig|   2 +-
 net/netfilter/Kconfig |  16 +-
 net/tipc/Kconfig  |   2 +-
 scripts/Kbuild.include|   4 +-
 scripts/Makefile.host |   2 +-
 scripts/kconfig/symbol.c  |   2 +-
 .../tests/err_recursive_dep/expected_stderr   |  14 +-
 sound/oss/dmasound/Kconfig|   6 +-
 48 files changed, 840 insertions(+), 561 deletions(-)
 rename Documentation/kbuild/{headers_install.txt => headers_install.rst} (96%)
 create mode 100644 Documentation/kbuild/index.rst
 create mode 100644 Documentation/kbuild/issues.rst
 rename Documentation/kbuild/{kbuild.txt => kbuild.rst} (72%)
 rename Documentation/kbuild/{kconfig-language.txt => kconfig-language.rst} 
(85%)
 rename Documentation/kbuild/{kconfig-macro-language.txt => 
kconfig-macro-language.rst} (94%)
 rename Documentation/kbuild/{kconfig.txt => kconfig.rst} (80%)
 rename Documentation/kbuild/{makefiles.txt => makefiles.rst} (83%)
 rename Documentation/kbuild/{modules.txt => modules.rst} (84%)

diff --git a/Documentation/admin-guide/README.rst 
b/Documentation/admin-guide/README.rst
index a582c780c3bd..cc6151fc0845 100644
--- a/Documentation/admin-guide/README.rst
+++ b/Documentation/admin-guide/README.rst
@@ -227,7 +227,7 @@ Configuring the kernel
  "make tinyconfig"  Configure the tiniest possible kernel.
 
You can find more information on using the Linux kernel config tools
-   in Documentation/kbuild/kconfig.txt.
+   in Documentation/kbuild/kconfig.rst.
 
  - NOTES on ``make config``:
 
diff --git a/Documentation/kbuild/headers_install.txt 
b/Documentation/kbuild/headers_install.rst
similarity index 96%
rename from Documentation/kbuild/headers_install.txt
rename to Documentation/kbuild/headers_install.rst
index f0153adb95e2..1ab7294e41ac 100644
--- a/Documentation/kbuild/headers_install.txt
+++ b/Documentation/kbuild/headers_install.rst
@@ -1,3 +1,4 @@
+===

[PATCH v4 13/28] docs: kdump: convert docs to ReST and rename to *.rst

2019-06-12 Thread Mauro Carvalho Chehab
Convert kdump documentation to ReST and add it to the
user faced manual, as the documents are mainly focused on
sysadmins that would be enabling kdump.

Note: the vmcoreinfo.rst has one very long title on one of its
sub-sections:


PG_lru|PG_private|PG_swapcache|PG_swapbacked|PG_slab|PG_hwpoision|PG_head_mask|PAGE_BUDDY_MAPCOUNT_VALUE(~PG_buddy)|PAGE_OFFLINE_MAPCOUNT_VALUE(~PG_offline)

I opted to break this one, into two entries with the same content,
in order to make it easier to display after being parsed in html and PDF.

The conversion is actually:
  - add blank lines and identation in order to identify paragraphs;
  - fix tables markups;
  - add some lists markups;
  - mark literal blocks;
  - adjust title markups.

At its new index.rst, let's add a :orphan: while this is not linked to
the main index.rst file, in order to avoid build warnings.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/admin-guide/bug-hunting.rst |   2 +-
 .../admin-guide/kernel-parameters.txt |   6 +-
 Documentation/kdump/index.rst |  21 +++
 Documentation/kdump/{kdump.txt => kdump.rst}  | 131 +++---
 .../kdump/{vmcoreinfo.txt => vmcoreinfo.rst}  |  59 
 .../powerpc/firmware-assisted-dump.txt|   2 +-
 .../translations/zh_CN/oops-tracing.txt   |   2 +-
 Documentation/watchdog/hpwdt.txt  |   2 +-
 arch/arm/Kconfig  |   2 +-
 arch/arm64/Kconfig|   2 +-
 arch/sh/Kconfig   |   2 +-
 arch/x86/Kconfig  |   4 +-
 12 files changed, 137 insertions(+), 98 deletions(-)
 create mode 100644 Documentation/kdump/index.rst
 rename Documentation/kdump/{kdump.txt => kdump.rst} (91%)
 rename Documentation/kdump/{vmcoreinfo.txt => vmcoreinfo.rst} (95%)

diff --git a/Documentation/admin-guide/bug-hunting.rst 
b/Documentation/admin-guide/bug-hunting.rst
index f278b289e260..b761aa2a51d2 100644
--- a/Documentation/admin-guide/bug-hunting.rst
+++ b/Documentation/admin-guide/bug-hunting.rst
@@ -90,7 +90,7 @@ the disk is not available then you have three options:
 run a null modem to a second machine and capture the output there
 using your favourite communication program.  Minicom works well.
 
-(3) Use Kdump (see Documentation/kdump/kdump.txt),
+(3) Use Kdump (see Documentation/kdump/kdump.rst),
 extract the kernel ring buffer from old memory with using dmesg
 gdbmacro in Documentation/kdump/gdbmacros.txt.
 
diff --git a/Documentation/admin-guide/kernel-parameters.txt 
b/Documentation/admin-guide/kernel-parameters.txt
index affed5d447de..c31373f39240 100644
--- a/Documentation/admin-guide/kernel-parameters.txt
+++ b/Documentation/admin-guide/kernel-parameters.txt
@@ -708,14 +708,14 @@
[KNL, x86_64] select a region under 4G first, and
fall back to reserve region above 4G when '@offset'
hasn't been specified.
-   See Documentation/kdump/kdump.txt for further details.
+   See Documentation/kdump/kdump.rst for further details.
 
crashkernel=range1:size1[,range2:size2,...][@offset]
[KNL] Same as above, but depends on the memory
in the running system. The syntax of range is
start-[end] where start and end are both
a memory unit (amount[KMG]). See also
-   Documentation/kdump/kdump.txt for an example.
+   Documentation/kdump/kdump.rst for an example.
 
crashkernel=size[KMG],high
[KNL, x86_64] range could be above 4G. Allow kernel
@@ -1207,7 +1207,7 @@
Specifies physical address of start of kernel core
image elf header and optionally the size. Generally
kexec loader will pass this option to capture kernel.
-   See Documentation/kdump/kdump.txt for details.
+   See Documentation/kdump/kdump.rst for details.
 
enable_mtrr_cleanup [X86]
The kernel tries to adjust MTRR layout from continuous
diff --git a/Documentation/kdump/index.rst b/Documentation/kdump/index.rst
new file mode 100644
index ..2b17fcf6867a
--- /dev/null
+++ b/Documentation/kdump/index.rst
@@ -0,0 +1,21 @@
+:orphan:
+
+
+Documentation for Kdump - The kexec-based Crash Dumping Solution
+
+
+This document includes overview, setup and installation, and analysis
+information.
+
+.. toctree::
+:maxdepth: 1
+
+kdump
+vmcoreinfo
+
+.. only::  subproject and html
+
+   Indices
+   ===
+
+   * :ref:`genindex`
diff --git a/Documentation/kdump/kdump.txt b/Documentation/kdump/kdump.rst
similarity index 91%

[PATCH v4 19/28] docs: powerpc: convert docs to ReST and rename to *.rst

2019-06-12 Thread Mauro Carvalho Chehab
Convert docs to ReST and add them to the arch-specific
book.

The conversion here was trivial, as almost every file there
was already using an elegant format close to ReST standard.

The changes were mostly to mark literal blocks and add a few
missing section title identifiers.

One note with regards to "--": on Sphinx, this can't be used
to identify a list, as it will format it badly. This can be
used, however, to identify a long hyphen - and "---" is an
even longer one.

At its new index.rst, let's add a :orphan: while this is not linked to
the main index.rst file, in order to avoid build warnings.

Signed-off-by: Mauro Carvalho Chehab 
Acked-by: Andrew Donnellan  # cxl
---
 Documentation/PCI/pci-error-recovery.rst  |  23 ++-
 .../{bootwrapper.txt => bootwrapper.rst}  |  28 +++-
 .../{cpu_families.txt => cpu_families.rst}|  23 +--
 .../{cpu_features.txt => cpu_features.rst}|   6 +-
 Documentation/powerpc/{cxl.txt => cxl.rst}|  46 --
 .../powerpc/{cxlflash.txt => cxlflash.rst}|  10 +-
 .../{DAWR-POWER9.txt => dawr-power9.rst}  |  15 +-
 Documentation/powerpc/{dscr.txt => dscr.rst}  |  18 +-
 ...ecovery.txt => eeh-pci-error-recovery.rst} | 108 ++--
 ...ed-dump.txt => firmware-assisted-dump.rst} | 117 +++--
 Documentation/powerpc/{hvcs.txt => hvcs.rst}  | 108 ++--
 Documentation/powerpc/index.rst   |  34 
 Documentation/powerpc/isa-versions.rst|  15 +-
 .../powerpc/{mpc52xx.txt => mpc52xx.rst}  |  12 +-
 ...nv.txt => pci_iov_resource_on_powernv.rst} |  15 +-
 .../powerpc/{pmu-ebb.txt => pmu-ebb.rst}  |   1 +
 Documentation/powerpc/ptrace.rst  | 156 ++
 Documentation/powerpc/ptrace.txt  | 151 -
 .../{qe_firmware.txt => qe_firmware.rst}  |  37 +++--
 .../{syscall64-abi.txt => syscall64-abi.rst}  |  29 ++--
 ...al_memory.txt => transactional_memory.rst} |  45 ++---
 MAINTAINERS   |   6 +-
 arch/powerpc/kernel/exceptions-64s.S  |   2 +-
 drivers/soc/fsl/qe/qe.c   |   2 +-
 drivers/tty/hvc/hvcs.c|   2 +-
 include/soc/fsl/qe/qe.h   |   2 +-
 26 files changed, 584 insertions(+), 427 deletions(-)
 rename Documentation/powerpc/{bootwrapper.txt => bootwrapper.rst} (93%)
 rename Documentation/powerpc/{cpu_families.txt => cpu_families.rst} (95%)
 rename Documentation/powerpc/{cpu_features.txt => cpu_features.rst} (97%)
 rename Documentation/powerpc/{cxl.txt => cxl.rst} (95%)
 rename Documentation/powerpc/{cxlflash.txt => cxlflash.rst} (98%)
 rename Documentation/powerpc/{DAWR-POWER9.txt => dawr-power9.rst} (95%)
 rename Documentation/powerpc/{dscr.txt => dscr.rst} (91%)
 rename Documentation/powerpc/{eeh-pci-error-recovery.txt => 
eeh-pci-error-recovery.rst} (82%)
 rename Documentation/powerpc/{firmware-assisted-dump.txt => 
firmware-assisted-dump.rst} (80%)
 rename Documentation/powerpc/{hvcs.txt => hvcs.rst} (91%)
 create mode 100644 Documentation/powerpc/index.rst
 rename Documentation/powerpc/{mpc52xx.txt => mpc52xx.rst} (91%)
 rename Documentation/powerpc/{pci_iov_resource_on_powernv.txt => 
pci_iov_resource_on_powernv.rst} (97%)
 rename Documentation/powerpc/{pmu-ebb.txt => pmu-ebb.rst} (99%)
 create mode 100644 Documentation/powerpc/ptrace.rst
 delete mode 100644 Documentation/powerpc/ptrace.txt
 rename Documentation/powerpc/{qe_firmware.txt => qe_firmware.rst} (95%)
 rename Documentation/powerpc/{syscall64-abi.txt => syscall64-abi.rst} (82%)
 rename Documentation/powerpc/{transactional_memory.txt => 
transactional_memory.rst} (93%)

diff --git a/Documentation/PCI/pci-error-recovery.rst 
b/Documentation/PCI/pci-error-recovery.rst
index 83db42092935..acc21ecca322 100644
--- a/Documentation/PCI/pci-error-recovery.rst
+++ b/Documentation/PCI/pci-error-recovery.rst
@@ -403,7 +403,7 @@ That is, the recovery API only requires that:
 .. note::
 
Implementation details for the powerpc platform are discussed in
-   the file Documentation/powerpc/eeh-pci-error-recovery.txt
+   the file Documentation/powerpc/eeh-pci-error-recovery.rst
 
As of this writing, there is a growing list of device drivers with
patches implementing error recovery. Not all of these patches are in
@@ -422,3 +422,24 @@ That is, the recovery API only requires that:
- drivers/net/cxgb3
- drivers/net/s2io.c
- drivers/net/qlge
+
+>>> As of this writing, there is a growing list of device drivers with
+>>> patches implementing error recovery. Not all of these patches are in
+>>> mainline yet. These may be used as "examples":
+>>>
+>>> drivers/scsi/ipr
+>>> drivers/scsi/sym53c8xx_2
+>>> drivers/scsi/qla2xxx
+>>> drivers/scsi/lpfc
+>>> drivers/next/bnx2.c
+>>> drivers/nex

Re: [PATCH v3 06/20] docs: mark orphan documents as such

2019-06-11 Thread Mauro Carvalho Chehab
Em Tue, 11 Jun 2019 19:52:04 +0300
Andy Shevchenko  escreveu:

> On Fri, Jun 7, 2019 at 10:04 PM Mauro Carvalho Chehab
>  wrote:
> > Sphinx doesn't like orphan documents:  
> 
> > Documentation/laptops/lg-laptop.rst: WARNING: document isn't included 
> > in any toctree  
> 
> >  Documentation/laptops/lg-laptop.rst | 2 ++  
> 
> > diff --git a/Documentation/laptops/lg-laptop.rst 
> > b/Documentation/laptops/lg-laptop.rst
> > index aa503ee9b3bc..f2c2ffe31101 100644
> > --- a/Documentation/laptops/lg-laptop.rst
> > +++ b/Documentation/laptops/lg-laptop.rst
> > @@ -1,5 +1,7 @@
> >  .. SPDX-License-Identifier: GPL-2.0+
> >
> > +:orphan:
> > +
> >  LG Gram laptop extra features
> >  =
> >  
> 
> Can we rather create a toc tree there?
> It was a first document in reST format in that folder.

Sure, but:

1) I have a patch converting the other files on this dir to rst:


https://git.linuxtv.org/mchehab/experimental.git/commit/?h=convert_rst_renames_v4.1=abc13233035fdfdbc5ef2f2fbd3d127a1ab15530

2) It probably makes sense to move the entire dir to
Documentation/admin-guide.

So, I would prefer to have the :orphan: here while (1) is not merged.

Thanks,
Mauro


[PATCH v3 14/33] docs: kbuild: convert docs to ReST and rename to *.rst

2019-06-08 Thread Mauro Carvalho Chehab
The kbuild documentation clearly shows that the documents
there are written at different times: some use markdown,
some use their own peculiar logic to split sections.

Convert everything to ReST without affecting too much
the author's style and avoiding adding uneeded markups.

The conversion is actually:
  - add blank lines and identation in order to identify paragraphs;
  - fix tables markups;
  - add some lists markups;
  - mark literal blocks;
  - adjust title markups.

At its new index.rst, let's add a :orphan: while this is not linked to
the main index.rst file, in order to avoid build warnings.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/admin-guide/README.rst  |   2 +-
 ...eaders_install.txt => headers_install.rst} |   5 +-
 Documentation/kbuild/index.rst|  27 +
 Documentation/kbuild/issues.rst   |  11 +
 .../kbuild/{kbuild.txt => kbuild.rst} | 119 ++--
 ...nfig-language.txt => kconfig-language.rst} | 232 
 ...anguage.txt => kconfig-macro-language.rst} |  37 +-
 .../kbuild/{kconfig.txt => kconfig.rst}   | 136 +++--
 .../kbuild/{makefiles.txt => makefiles.rst}   | 530 +++---
 .../kbuild/{modules.txt => modules.rst}   | 168 +++---
 Documentation/kernel-hacking/hacking.rst  |   4 +-
 Documentation/process/coding-style.rst|   2 +-
 Documentation/process/submit-checklist.rst|   2 +-
 .../it_IT/kernel-hacking/hacking.rst  |   4 +-
 .../it_IT/process/coding-style.rst|   2 +-
 .../it_IT/process/submit-checklist.rst|   2 +-
 .../zh_CN/process/coding-style.rst|   2 +-
 .../zh_CN/process/submit-checklist.rst|   2 +-
 Kconfig   |   2 +-
 arch/arc/plat-eznps/Kconfig   |   2 +-
 arch/c6x/Kconfig  |   2 +-
 arch/microblaze/Kconfig.debug |   2 +-
 arch/microblaze/Kconfig.platform  |   2 +-
 arch/nds32/Kconfig|   2 +-
 arch/openrisc/Kconfig |   2 +-
 arch/powerpc/sysdev/Kconfig   |   2 +-
 arch/riscv/Kconfig|   2 +-
 drivers/auxdisplay/Kconfig|   2 +-
 drivers/firmware/Kconfig  |   2 +-
 drivers/mtd/devices/Kconfig   |   2 +-
 drivers/net/ethernet/smsc/Kconfig |   6 +-
 drivers/net/wireless/intel/iwlegacy/Kconfig   |   4 +-
 drivers/net/wireless/intel/iwlwifi/Kconfig|   2 +-
 drivers/parport/Kconfig   |   2 +-
 drivers/scsi/Kconfig  |   4 +-
 drivers/staging/sm750fb/Kconfig   |   2 +-
 drivers/usb/misc/Kconfig  |   4 +-
 drivers/video/fbdev/Kconfig   |  14 +-
 net/bridge/netfilter/Kconfig  |   2 +-
 net/ipv4/netfilter/Kconfig|   2 +-
 net/ipv6/netfilter/Kconfig|   2 +-
 net/netfilter/Kconfig |  16 +-
 net/tipc/Kconfig  |   2 +-
 scripts/Kbuild.include|   4 +-
 scripts/Makefile.host |   2 +-
 scripts/kconfig/symbol.c  |   2 +-
 .../tests/err_recursive_dep/expected_stderr   |  14 +-
 sound/oss/dmasound/Kconfig|   6 +-
 48 files changed, 840 insertions(+), 561 deletions(-)
 rename Documentation/kbuild/{headers_install.txt => headers_install.rst} (96%)
 create mode 100644 Documentation/kbuild/index.rst
 create mode 100644 Documentation/kbuild/issues.rst
 rename Documentation/kbuild/{kbuild.txt => kbuild.rst} (72%)
 rename Documentation/kbuild/{kconfig-language.txt => kconfig-language.rst} 
(85%)
 rename Documentation/kbuild/{kconfig-macro-language.txt => 
kconfig-macro-language.rst} (94%)
 rename Documentation/kbuild/{kconfig.txt => kconfig.rst} (80%)
 rename Documentation/kbuild/{makefiles.txt => makefiles.rst} (83%)
 rename Documentation/kbuild/{modules.txt => modules.rst} (84%)

diff --git a/Documentation/admin-guide/README.rst 
b/Documentation/admin-guide/README.rst
index a582c780c3bd..cc6151fc0845 100644
--- a/Documentation/admin-guide/README.rst
+++ b/Documentation/admin-guide/README.rst
@@ -227,7 +227,7 @@ Configuring the kernel
  "make tinyconfig"  Configure the tiniest possible kernel.
 
You can find more information on using the Linux kernel config tools
-   in Documentation/kbuild/kconfig.txt.
+   in Documentation/kbuild/kconfig.rst.
 
  - NOTES on ``make config``:
 
diff --git a/Documentation/kbuild/headers_install.txt 
b/Documentation/kbuild/headers_install.rst
similarity index 96%
rename from Documentation/kbuild/headers_install.txt
rename to Documentation/kbuild/headers_install.rst
index f0153adb95e2..1ab7294e41ac 100644
--- a/Documentation/kbuild/headers_install.txt
+++ b/Documentation/kbuild/headers_install.rst
@@ -1,3 +1,4 @@
+===

[PATCH v3 15/33] docs: kdump: convert docs to ReST and rename to *.rst

2019-06-08 Thread Mauro Carvalho Chehab
Convert kdump documentation to ReST and add it to the
user faced manual, as the documents are mainly focused on
sysadmins that would be enabling kdump.

Note: the vmcoreinfo.rst has one very long title on one of its
sub-sections:


PG_lru|PG_private|PG_swapcache|PG_swapbacked|PG_slab|PG_hwpoision|PG_head_mask|PAGE_BUDDY_MAPCOUNT_VALUE(~PG_buddy)|PAGE_OFFLINE_MAPCOUNT_VALUE(~PG_offline)

I opted to break this one, into two entries with the same content,
in order to make it easier to display after being parsed in html and PDF.

The conversion is actually:
  - add blank lines and identation in order to identify paragraphs;
  - fix tables markups;
  - add some lists markups;
  - mark literal blocks;
  - adjust title markups.

At its new index.rst, let's add a :orphan: while this is not linked to
the main index.rst file, in order to avoid build warnings.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/admin-guide/bug-hunting.rst |   2 +-
 .../admin-guide/kernel-parameters.txt |   6 +-
 Documentation/kdump/index.rst |  21 +++
 Documentation/kdump/{kdump.txt => kdump.rst}  | 131 +++---
 .../kdump/{vmcoreinfo.txt => vmcoreinfo.rst}  |  59 
 .../powerpc/firmware-assisted-dump.txt|   2 +-
 .../translations/zh_CN/oops-tracing.txt   |   2 +-
 Documentation/watchdog/hpwdt.txt  |   2 +-
 arch/arm/Kconfig  |   2 +-
 arch/arm64/Kconfig|   2 +-
 arch/sh/Kconfig   |   2 +-
 arch/x86/Kconfig  |   4 +-
 12 files changed, 137 insertions(+), 98 deletions(-)
 create mode 100644 Documentation/kdump/index.rst
 rename Documentation/kdump/{kdump.txt => kdump.rst} (91%)
 rename Documentation/kdump/{vmcoreinfo.txt => vmcoreinfo.rst} (95%)

diff --git a/Documentation/admin-guide/bug-hunting.rst 
b/Documentation/admin-guide/bug-hunting.rst
index f278b289e260..b761aa2a51d2 100644
--- a/Documentation/admin-guide/bug-hunting.rst
+++ b/Documentation/admin-guide/bug-hunting.rst
@@ -90,7 +90,7 @@ the disk is not available then you have three options:
 run a null modem to a second machine and capture the output there
 using your favourite communication program.  Minicom works well.
 
-(3) Use Kdump (see Documentation/kdump/kdump.txt),
+(3) Use Kdump (see Documentation/kdump/kdump.rst),
 extract the kernel ring buffer from old memory with using dmesg
 gdbmacro in Documentation/kdump/gdbmacros.txt.
 
diff --git a/Documentation/admin-guide/kernel-parameters.txt 
b/Documentation/admin-guide/kernel-parameters.txt
index e4544f0335e3..9789328f5e9d 100644
--- a/Documentation/admin-guide/kernel-parameters.txt
+++ b/Documentation/admin-guide/kernel-parameters.txt
@@ -708,14 +708,14 @@
[KNL, x86_64] select a region under 4G first, and
fall back to reserve region above 4G when '@offset'
hasn't been specified.
-   See Documentation/kdump/kdump.txt for further details.
+   See Documentation/kdump/kdump.rst for further details.
 
crashkernel=range1:size1[,range2:size2,...][@offset]
[KNL] Same as above, but depends on the memory
in the running system. The syntax of range is
start-[end] where start and end are both
a memory unit (amount[KMG]). See also
-   Documentation/kdump/kdump.txt for an example.
+   Documentation/kdump/kdump.rst for an example.
 
crashkernel=size[KMG],high
[KNL, x86_64] range could be above 4G. Allow kernel
@@ -1207,7 +1207,7 @@
Specifies physical address of start of kernel core
image elf header and optionally the size. Generally
kexec loader will pass this option to capture kernel.
-   See Documentation/kdump/kdump.txt for details.
+   See Documentation/kdump/kdump.rst for details.
 
enable_mtrr_cleanup [X86]
The kernel tries to adjust MTRR layout from continuous
diff --git a/Documentation/kdump/index.rst b/Documentation/kdump/index.rst
new file mode 100644
index ..2b17fcf6867a
--- /dev/null
+++ b/Documentation/kdump/index.rst
@@ -0,0 +1,21 @@
+:orphan:
+
+
+Documentation for Kdump - The kexec-based Crash Dumping Solution
+
+
+This document includes overview, setup and installation, and analysis
+information.
+
+.. toctree::
+:maxdepth: 1
+
+kdump
+vmcoreinfo
+
+.. only::  subproject and html
+
+   Indices
+   ===
+
+   * :ref:`genindex`
diff --git a/Documentation/kdump/kdump.txt b/Documentation/kdump/kdump.rst
similarity index 91%

[PATCH v3 21/33] docs: powerpc: convert docs to ReST and rename to *.rst

2019-06-08 Thread Mauro Carvalho Chehab
Convert docs to ReST and add them to the arch-specific
book.

The conversion here was trivial, as almost every file there
was already using an elegant format close to ReST standard.

The changes were mostly to mark literal blocks and add a few
missing section title identifiers.

One note with regards to "--": on Sphinx, this can't be used
to identify a list, as it will format it badly. This can be
used, however, to identify a long hyphen - and "---" is an
even longer one.

At its new index.rst, let's add a :orphan: while this is not linked to
the main index.rst file, in order to avoid build warnings.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/PCI/pci-error-recovery.rst  |  23 ++-
 .../{bootwrapper.txt => bootwrapper.rst}  |  28 ++-
 .../{cpu_families.txt => cpu_families.rst}|  23 +--
 .../{cpu_features.txt => cpu_features.rst}|   6 +-
 Documentation/powerpc/{cxl.txt => cxl.rst}|  46 +++--
 .../powerpc/{cxlflash.txt => cxlflash.rst}|  10 +-
 .../{DAWR-POWER9.txt => dawr-power9.rst}  |  15 +-
 Documentation/powerpc/{dscr.txt => dscr.rst}  |  18 +-
 ...ecovery.txt => eeh-pci-error-recovery.rst} | 108 +--
 ...ed-dump.txt => firmware-assisted-dump.rst} | 117 ++--
 Documentation/powerpc/{hvcs.txt => hvcs.rst}  | 108 ++-
 Documentation/powerpc/index.rst   |  34 
 Documentation/powerpc/isa-versions.rst|  15 +-
 .../powerpc/{mpc52xx.txt => mpc52xx.rst}  |  12 +-
 ...nv.txt => pci_iov_resource_on_powernv.rst} |  15 +-
 .../powerpc/{pmu-ebb.txt => pmu-ebb.rst}  |   1 +
 .../powerpc/{ptrace.txt => ptrace.rst}| 169 +-
 .../{qe_firmware.txt => qe_firmware.rst}  |  37 ++--
 .../{syscall64-abi.txt => syscall64-abi.rst}  |  29 +--
 ...al_memory.txt => transactional_memory.rst} |  45 ++---
 MAINTAINERS   |   6 +-
 arch/powerpc/kernel/exceptions-64s.S  |   2 +-
 drivers/soc/fsl/qe/qe.c   |   2 +-
 drivers/tty/hvc/hvcs.c|   2 +-
 include/soc/fsl/qe/qe.h   |   2 +-
 25 files changed, 515 insertions(+), 358 deletions(-)
 rename Documentation/powerpc/{bootwrapper.txt => bootwrapper.rst} (93%)
 rename Documentation/powerpc/{cpu_families.txt => cpu_families.rst} (95%)
 rename Documentation/powerpc/{cpu_features.txt => cpu_features.rst} (97%)
 rename Documentation/powerpc/{cxl.txt => cxl.rst} (95%)
 rename Documentation/powerpc/{cxlflash.txt => cxlflash.rst} (98%)
 rename Documentation/powerpc/{DAWR-POWER9.txt => dawr-power9.rst} (95%)
 rename Documentation/powerpc/{dscr.txt => dscr.rst} (91%)
 rename Documentation/powerpc/{eeh-pci-error-recovery.txt => 
eeh-pci-error-recovery.rst} (82%)
 rename Documentation/powerpc/{firmware-assisted-dump.txt => 
firmware-assisted-dump.rst} (80%)
 rename Documentation/powerpc/{hvcs.txt => hvcs.rst} (91%)
 create mode 100644 Documentation/powerpc/index.rst
 rename Documentation/powerpc/{mpc52xx.txt => mpc52xx.rst} (91%)
 rename Documentation/powerpc/{pci_iov_resource_on_powernv.txt => 
pci_iov_resource_on_powernv.rst} (97%)
 rename Documentation/powerpc/{pmu-ebb.txt => pmu-ebb.rst} (99%)
 rename Documentation/powerpc/{ptrace.txt => ptrace.rst} (48%)
 rename Documentation/powerpc/{qe_firmware.txt => qe_firmware.rst} (95%)
 rename Documentation/powerpc/{syscall64-abi.txt => syscall64-abi.rst} (82%)
 rename Documentation/powerpc/{transactional_memory.txt => 
transactional_memory.rst} (93%)

diff --git a/Documentation/PCI/pci-error-recovery.rst 
b/Documentation/PCI/pci-error-recovery.rst
index 83db42092935..acc21ecca322 100644
--- a/Documentation/PCI/pci-error-recovery.rst
+++ b/Documentation/PCI/pci-error-recovery.rst
@@ -403,7 +403,7 @@ That is, the recovery API only requires that:
 .. note::
 
Implementation details for the powerpc platform are discussed in
-   the file Documentation/powerpc/eeh-pci-error-recovery.txt
+   the file Documentation/powerpc/eeh-pci-error-recovery.rst
 
As of this writing, there is a growing list of device drivers with
patches implementing error recovery. Not all of these patches are in
@@ -422,3 +422,24 @@ That is, the recovery API only requires that:
- drivers/net/cxgb3
- drivers/net/s2io.c
- drivers/net/qlge
+
+>>> As of this writing, there is a growing list of device drivers with
+>>> patches implementing error recovery. Not all of these patches are in
+>>> mainline yet. These may be used as "examples":
+>>>
+>>> drivers/scsi/ipr
+>>> drivers/scsi/sym53c8xx_2
+>>> drivers/scsi/qla2xxx
+>>> drivers/scsi/lpfc
+>>> drivers/next/bnx2.c
+>>> drivers/next/e100.c
+>>> drivers/net/e1000
+>>> drivers/net/e1000e
+>>> drivers/net/ixgb
+>>> drivers/net/ixgbe

[PATCH v3 15/20] docs: move protection-keys.rst to the core-api book

2019-06-07 Thread Mauro Carvalho Chehab
This document is used by multiple architectures:

$ echo $(git grep -l  pkey_mprotect arch|cut -d'/' -f 2|sort|uniq)
alpha arm arm64 ia64 m68k microblaze mips parisc powerpc s390 sh sparc 
x86 xtensa

So, let's move it to the core book and adjust the links to it
accordingly.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/core-api/index.rst| 1 +
 Documentation/{x86 => core-api}/protection-keys.rst | 0
 Documentation/x86/index.rst | 1 -
 arch/powerpc/Kconfig| 2 +-
 arch/x86/Kconfig| 2 +-
 tools/testing/selftests/x86/protection_keys.c   | 2 +-
 6 files changed, 4 insertions(+), 4 deletions(-)
 rename Documentation/{x86 => core-api}/protection-keys.rst (100%)

diff --git a/Documentation/core-api/index.rst b/Documentation/core-api/index.rst
index ee1bb8983a88..2466a4c51031 100644
--- a/Documentation/core-api/index.rst
+++ b/Documentation/core-api/index.rst
@@ -34,6 +34,7 @@ Core utilities
timekeeping
boot-time-mm
memory-hotplug
+   protection-keys
 
 
 Interfaces for kernel debugging
diff --git a/Documentation/x86/protection-keys.rst 
b/Documentation/core-api/protection-keys.rst
similarity index 100%
rename from Documentation/x86/protection-keys.rst
rename to Documentation/core-api/protection-keys.rst
diff --git a/Documentation/x86/index.rst b/Documentation/x86/index.rst
index ae36fc5fc649..f2de1b2d3ac7 100644
--- a/Documentation/x86/index.rst
+++ b/Documentation/x86/index.rst
@@ -19,7 +19,6 @@ x86-specific Documentation
tlb
mtrr
pat
-   protection-keys
intel_mpx
amd-memory-encryption
pti
diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig
index 8c1c636308c8..3b795a0cab62 100644
--- a/arch/powerpc/Kconfig
+++ b/arch/powerpc/Kconfig
@@ -898,7 +898,7 @@ config PPC_MEM_KEYS
  page-based protections, but without requiring modification of the
  page tables when an application changes protection domains.
 
- For details, see Documentation/vm/protection-keys.rst
+ For details, see Documentation/core-api/protection-keys.rst
 
  If unsure, say y.
 
diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
index 2bbbd4d1ba31..d87d53fcd261 100644
--- a/arch/x86/Kconfig
+++ b/arch/x86/Kconfig
@@ -1911,7 +1911,7 @@ config X86_INTEL_MEMORY_PROTECTION_KEYS
  page-based protections, but without requiring modification of the
  page tables when an application changes protection domains.
 
- For details, see Documentation/x86/protection-keys.txt
+ For details, see Documentation/core-api/protection-keys.rst
 
  If unsure, say y.
 
diff --git a/tools/testing/selftests/x86/protection_keys.c 
b/tools/testing/selftests/x86/protection_keys.c
index 5d546dcdbc80..480995bceefa 100644
--- a/tools/testing/selftests/x86/protection_keys.c
+++ b/tools/testing/selftests/x86/protection_keys.c
@@ -1,6 +1,6 @@
 // SPDX-License-Identifier: GPL-2.0
 /*
- * Tests x86 Memory Protection Keys (see Documentation/x86/protection-keys.txt)
+ * Tests x86 Memory Protection Keys (see 
Documentation/core-api/protection-keys.rst)
  *
  * There are examples in here of:
  *  * how to set protection keys on memory
-- 
2.21.0



[PATCH v3 06/20] docs: mark orphan documents as such

2019-06-07 Thread Mauro Carvalho Chehab
Sphinx doesn't like orphan documents:

Documentation/accelerators/ocxl.rst: WARNING: document isn't included in 
any toctree
Documentation/arm/stm32/overview.rst: WARNING: document isn't included in 
any toctree
Documentation/arm/stm32/stm32f429-overview.rst: WARNING: document isn't 
included in any toctree
Documentation/arm/stm32/stm32f746-overview.rst: WARNING: document isn't 
included in any toctree
Documentation/arm/stm32/stm32f769-overview.rst: WARNING: document isn't 
included in any toctree
Documentation/arm/stm32/stm32h743-overview.rst: WARNING: document isn't 
included in any toctree
Documentation/arm/stm32/stm32mp157-overview.rst: WARNING: document isn't 
included in any toctree
Documentation/gpu/msm-crash-dump.rst: WARNING: document isn't included in 
any toctree
Documentation/interconnect/interconnect.rst: WARNING: document isn't 
included in any toctree
Documentation/laptops/lg-laptop.rst: WARNING: document isn't included in 
any toctree
Documentation/powerpc/isa-versions.rst: WARNING: document isn't included in 
any toctree
Documentation/virtual/kvm/amd-memory-encryption.rst: WARNING: document 
isn't included in any toctree
Documentation/virtual/kvm/vcpu-requests.rst: WARNING: document isn't 
included in any toctree

So, while they aren't on any toctree, add :orphan: to them, in order
to silent this warning.

Signed-off-by: Mauro Carvalho Chehab 
Acked-by: Andrew Donnellan 
---
 Documentation/accelerators/ocxl.rst | 2 ++
 Documentation/arm/stm32/overview.rst| 2 ++
 Documentation/arm/stm32/stm32f429-overview.rst  | 2 ++
 Documentation/arm/stm32/stm32f746-overview.rst  | 2 ++
 Documentation/arm/stm32/stm32f769-overview.rst  | 2 ++
 Documentation/arm/stm32/stm32h743-overview.rst  | 2 ++
 Documentation/arm/stm32/stm32mp157-overview.rst | 2 ++
 Documentation/gpu/msm-crash-dump.rst| 2 ++
 Documentation/interconnect/interconnect.rst | 2 ++
 Documentation/laptops/lg-laptop.rst | 2 ++
 Documentation/powerpc/isa-versions.rst  | 2 ++
 11 files changed, 22 insertions(+)

diff --git a/Documentation/accelerators/ocxl.rst 
b/Documentation/accelerators/ocxl.rst
index 14cefc020e2d..b1cea19a90f5 100644
--- a/Documentation/accelerators/ocxl.rst
+++ b/Documentation/accelerators/ocxl.rst
@@ -1,3 +1,5 @@
+:orphan:
+
 
 OpenCAPI (Open Coherent Accelerator Processor Interface)
 
diff --git a/Documentation/arm/stm32/overview.rst 
b/Documentation/arm/stm32/overview.rst
index 85cfc8410798..f7e734153860 100644
--- a/Documentation/arm/stm32/overview.rst
+++ b/Documentation/arm/stm32/overview.rst
@@ -1,3 +1,5 @@
+:orphan:
+
 
 STM32 ARM Linux Overview
 
diff --git a/Documentation/arm/stm32/stm32f429-overview.rst 
b/Documentation/arm/stm32/stm32f429-overview.rst
index 18feda97f483..65bbb1c3b423 100644
--- a/Documentation/arm/stm32/stm32f429-overview.rst
+++ b/Documentation/arm/stm32/stm32f429-overview.rst
@@ -1,3 +1,5 @@
+:orphan:
+
 STM32F429 Overview
 ==
 
diff --git a/Documentation/arm/stm32/stm32f746-overview.rst 
b/Documentation/arm/stm32/stm32f746-overview.rst
index b5f4b6ce7656..42d593085015 100644
--- a/Documentation/arm/stm32/stm32f746-overview.rst
+++ b/Documentation/arm/stm32/stm32f746-overview.rst
@@ -1,3 +1,5 @@
+:orphan:
+
 STM32F746 Overview
 ==
 
diff --git a/Documentation/arm/stm32/stm32f769-overview.rst 
b/Documentation/arm/stm32/stm32f769-overview.rst
index 228656ced2fe..f6adac862b17 100644
--- a/Documentation/arm/stm32/stm32f769-overview.rst
+++ b/Documentation/arm/stm32/stm32f769-overview.rst
@@ -1,3 +1,5 @@
+:orphan:
+
 STM32F769 Overview
 ==
 
diff --git a/Documentation/arm/stm32/stm32h743-overview.rst 
b/Documentation/arm/stm32/stm32h743-overview.rst
index 3458dc00095d..c525835e7473 100644
--- a/Documentation/arm/stm32/stm32h743-overview.rst
+++ b/Documentation/arm/stm32/stm32h743-overview.rst
@@ -1,3 +1,5 @@
+:orphan:
+
 STM32H743 Overview
 ==
 
diff --git a/Documentation/arm/stm32/stm32mp157-overview.rst 
b/Documentation/arm/stm32/stm32mp157-overview.rst
index 62e176d47ca7..2c52cd020601 100644
--- a/Documentation/arm/stm32/stm32mp157-overview.rst
+++ b/Documentation/arm/stm32/stm32mp157-overview.rst
@@ -1,3 +1,5 @@
+:orphan:
+
 STM32MP157 Overview
 ===
 
diff --git a/Documentation/gpu/msm-crash-dump.rst 
b/Documentation/gpu/msm-crash-dump.rst
index 757cd257e0d8..240ef200f76c 100644
--- a/Documentation/gpu/msm-crash-dump.rst
+++ b/Documentation/gpu/msm-crash-dump.rst
@@ -1,3 +1,5 @@
+:orphan:
+
 =
 MSM Crash Dump Format
 =
diff --git a/Documentation/interconnect/interconnect.rst 
b/Documentation/interconnect/interconnect.rst
index c3e004893796..56e331dab70e 100644
--- a/Documentation/interconnect/interconnect.rst

[PATCH v2 18/22] docs: move protection-keys.rst to the core-api book

2019-06-04 Thread Mauro Carvalho Chehab
This document is used by multiple architectures:

$ echo $(git grep -l  pkey_mprotect arch|cut -d'/' -f 2|sort|uniq)
alpha arm arm64 ia64 m68k microblaze mips parisc powerpc s390 sh sparc 
x86 xtensa

So, let's move it to the core book and adjust the links to it
accordingly.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/core-api/index.rst| 1 +
 Documentation/{x86 => core-api}/protection-keys.rst | 0
 Documentation/x86/index.rst | 1 -
 arch/powerpc/Kconfig| 2 +-
 arch/x86/Kconfig| 2 +-
 tools/testing/selftests/x86/protection_keys.c   | 2 +-
 6 files changed, 4 insertions(+), 4 deletions(-)
 rename Documentation/{x86 => core-api}/protection-keys.rst (100%)

diff --git a/Documentation/core-api/index.rst b/Documentation/core-api/index.rst
index ee1bb8983a88..2466a4c51031 100644
--- a/Documentation/core-api/index.rst
+++ b/Documentation/core-api/index.rst
@@ -34,6 +34,7 @@ Core utilities
timekeeping
boot-time-mm
memory-hotplug
+   protection-keys
 
 
 Interfaces for kernel debugging
diff --git a/Documentation/x86/protection-keys.rst 
b/Documentation/core-api/protection-keys.rst
similarity index 100%
rename from Documentation/x86/protection-keys.rst
rename to Documentation/core-api/protection-keys.rst
diff --git a/Documentation/x86/index.rst b/Documentation/x86/index.rst
index ae36fc5fc649..f2de1b2d3ac7 100644
--- a/Documentation/x86/index.rst
+++ b/Documentation/x86/index.rst
@@ -19,7 +19,6 @@ x86-specific Documentation
tlb
mtrr
pat
-   protection-keys
intel_mpx
amd-memory-encryption
pti
diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig
index 1120ff8ac715..e437aa3e78b4 100644
--- a/arch/powerpc/Kconfig
+++ b/arch/powerpc/Kconfig
@@ -898,7 +898,7 @@ config PPC_MEM_KEYS
  page-based protections, but without requiring modification of the
  page tables when an application changes protection domains.
 
- For details, see Documentation/vm/protection-keys.rst
+ For details, see Documentation/core-api/protection-keys.rst
 
  If unsure, say y.
 
diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
index 23de3b9da480..61244bdb886f 100644
--- a/arch/x86/Kconfig
+++ b/arch/x86/Kconfig
@@ -1911,7 +1911,7 @@ config X86_INTEL_MEMORY_PROTECTION_KEYS
  page-based protections, but without requiring modification of the
  page tables when an application changes protection domains.
 
- For details, see Documentation/x86/protection-keys.txt
+ For details, see Documentation/core-api/protection-keys.rst
 
  If unsure, say y.
 
diff --git a/tools/testing/selftests/x86/protection_keys.c 
b/tools/testing/selftests/x86/protection_keys.c
index 5d546dcdbc80..480995bceefa 100644
--- a/tools/testing/selftests/x86/protection_keys.c
+++ b/tools/testing/selftests/x86/protection_keys.c
@@ -1,6 +1,6 @@
 // SPDX-License-Identifier: GPL-2.0
 /*
- * Tests x86 Memory Protection Keys (see Documentation/x86/protection-keys.txt)
+ * Tests x86 Memory Protection Keys (see 
Documentation/core-api/protection-keys.rst)
  *
  * There are examples in here of:
  *  * how to set protection keys on memory
-- 
2.21.0



[PATCH v2 06/22] docs: mark orphan documents as such

2019-06-04 Thread Mauro Carvalho Chehab
Sphinx doesn't like orphan documents:

Documentation/accelerators/ocxl.rst: WARNING: document isn't included in 
any toctree
Documentation/arm/stm32/overview.rst: WARNING: document isn't included in 
any toctree
Documentation/arm/stm32/stm32f429-overview.rst: WARNING: document isn't 
included in any toctree
Documentation/arm/stm32/stm32f746-overview.rst: WARNING: document isn't 
included in any toctree
Documentation/arm/stm32/stm32f769-overview.rst: WARNING: document isn't 
included in any toctree
Documentation/arm/stm32/stm32h743-overview.rst: WARNING: document isn't 
included in any toctree
Documentation/arm/stm32/stm32mp157-overview.rst: WARNING: document isn't 
included in any toctree
Documentation/gpu/msm-crash-dump.rst: WARNING: document isn't included in 
any toctree
Documentation/interconnect/interconnect.rst: WARNING: document isn't 
included in any toctree
Documentation/laptops/lg-laptop.rst: WARNING: document isn't included in 
any toctree
Documentation/powerpc/isa-versions.rst: WARNING: document isn't included in 
any toctree
Documentation/virtual/kvm/amd-memory-encryption.rst: WARNING: document 
isn't included in any toctree
Documentation/virtual/kvm/vcpu-requests.rst: WARNING: document isn't 
included in any toctree

So, while they aren't on any toctree, add :orphan: to them, in order
to silent this warning.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/accelerators/ocxl.rst | 2 ++
 Documentation/arm/stm32/overview.rst| 2 ++
 Documentation/arm/stm32/stm32f429-overview.rst  | 2 ++
 Documentation/arm/stm32/stm32f746-overview.rst  | 2 ++
 Documentation/arm/stm32/stm32f769-overview.rst  | 2 ++
 Documentation/arm/stm32/stm32h743-overview.rst  | 2 ++
 Documentation/arm/stm32/stm32mp157-overview.rst | 2 ++
 Documentation/gpu/msm-crash-dump.rst| 2 ++
 Documentation/interconnect/interconnect.rst | 2 ++
 Documentation/laptops/lg-laptop.rst | 2 ++
 Documentation/powerpc/isa-versions.rst  | 2 ++
 11 files changed, 22 insertions(+)

diff --git a/Documentation/accelerators/ocxl.rst 
b/Documentation/accelerators/ocxl.rst
index 14cefc020e2d..b1cea19a90f5 100644
--- a/Documentation/accelerators/ocxl.rst
+++ b/Documentation/accelerators/ocxl.rst
@@ -1,3 +1,5 @@
+:orphan:
+
 
 OpenCAPI (Open Coherent Accelerator Processor Interface)
 
diff --git a/Documentation/arm/stm32/overview.rst 
b/Documentation/arm/stm32/overview.rst
index 85cfc8410798..f7e734153860 100644
--- a/Documentation/arm/stm32/overview.rst
+++ b/Documentation/arm/stm32/overview.rst
@@ -1,3 +1,5 @@
+:orphan:
+
 
 STM32 ARM Linux Overview
 
diff --git a/Documentation/arm/stm32/stm32f429-overview.rst 
b/Documentation/arm/stm32/stm32f429-overview.rst
index 18feda97f483..65bbb1c3b423 100644
--- a/Documentation/arm/stm32/stm32f429-overview.rst
+++ b/Documentation/arm/stm32/stm32f429-overview.rst
@@ -1,3 +1,5 @@
+:orphan:
+
 STM32F429 Overview
 ==
 
diff --git a/Documentation/arm/stm32/stm32f746-overview.rst 
b/Documentation/arm/stm32/stm32f746-overview.rst
index b5f4b6ce7656..42d593085015 100644
--- a/Documentation/arm/stm32/stm32f746-overview.rst
+++ b/Documentation/arm/stm32/stm32f746-overview.rst
@@ -1,3 +1,5 @@
+:orphan:
+
 STM32F746 Overview
 ==
 
diff --git a/Documentation/arm/stm32/stm32f769-overview.rst 
b/Documentation/arm/stm32/stm32f769-overview.rst
index 228656ced2fe..f6adac862b17 100644
--- a/Documentation/arm/stm32/stm32f769-overview.rst
+++ b/Documentation/arm/stm32/stm32f769-overview.rst
@@ -1,3 +1,5 @@
+:orphan:
+
 STM32F769 Overview
 ==
 
diff --git a/Documentation/arm/stm32/stm32h743-overview.rst 
b/Documentation/arm/stm32/stm32h743-overview.rst
index 3458dc00095d..c525835e7473 100644
--- a/Documentation/arm/stm32/stm32h743-overview.rst
+++ b/Documentation/arm/stm32/stm32h743-overview.rst
@@ -1,3 +1,5 @@
+:orphan:
+
 STM32H743 Overview
 ==
 
diff --git a/Documentation/arm/stm32/stm32mp157-overview.rst 
b/Documentation/arm/stm32/stm32mp157-overview.rst
index 62e176d47ca7..2c52cd020601 100644
--- a/Documentation/arm/stm32/stm32mp157-overview.rst
+++ b/Documentation/arm/stm32/stm32mp157-overview.rst
@@ -1,3 +1,5 @@
+:orphan:
+
 STM32MP157 Overview
 ===
 
diff --git a/Documentation/gpu/msm-crash-dump.rst 
b/Documentation/gpu/msm-crash-dump.rst
index 757cd257e0d8..240ef200f76c 100644
--- a/Documentation/gpu/msm-crash-dump.rst
+++ b/Documentation/gpu/msm-crash-dump.rst
@@ -1,3 +1,5 @@
+:orphan:
+
 =
 MSM Crash Dump Format
 =
diff --git a/Documentation/interconnect/interconnect.rst 
b/Documentation/interconnect/interconnect.rst
index c3e004893796..56e331dab70e 100644
--- a/Documentation/interconnect/interconnect.rst
+++ b/Documentation

Re: [PATCH 22/22] docs: fix broken documentation links

2019-06-04 Thread Mauro Carvalho Chehab
Em Tue, 4 Jun 2019 06:46:14 -0300
Mauro Carvalho Chehab  escreveu:

> Em Mon, 3 Jun 2019 09:34:15 +0200
> Christophe Leroy  escreveu:
> 

> > [...]
> > 
> > > diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig
> > > index 8c1c636308c8..e868d2bd48b8 100644
> > > --- a/arch/powerpc/Kconfig
> > > +++ b/arch/powerpc/Kconfig
> > > @@ -898,7 +898,7 @@ config PPC_MEM_KEYS
> > > page-based protections, but without requiring modification of 
> > > the
> > > page tables when an application changes protection domains.
> > >   
> > > -   For details, see Documentation/vm/protection-keys.rst
> > > +   For details, see Documentation/x86/protection-keys.rst  
> > 
> > It looks strange to reference an x86 file, for powerpc arch.
> 
> Indeed. Yet, seeking for the API documented there:
> 
>  $ git grep -l pkey_mprotect
> Documentation/x86/protection-keys.rst
> arch/alpha/kernel/syscalls/syscall.tbl
> arch/arm/tools/syscall.tbl
> arch/arm64/include/asm/unistd32.h
> arch/ia64/kernel/syscalls/syscall.tbl
> arch/m68k/kernel/syscalls/syscall.tbl
> arch/microblaze/kernel/syscalls/syscall.tbl
> arch/mips/kernel/syscalls/syscall_n32.tbl
> arch/mips/kernel/syscalls/syscall_n64.tbl
> arch/mips/kernel/syscalls/syscall_o32.tbl
> arch/parisc/kernel/syscalls/syscall.tbl
> arch/powerpc/kernel/syscalls/syscall.tbl
> arch/s390/kernel/syscalls/syscall.tbl
> arch/sh/kernel/syscalls/syscall.tbl
> arch/sparc/kernel/syscalls/syscall.tbl
> arch/x86/entry/syscalls/syscall_32.tbl
> arch/x86/entry/syscalls/syscall_64.tbl
> arch/xtensa/kernel/syscalls/syscall.tbl
> include/linux/syscalls.h
> include/uapi/asm-generic/unistd.h
> kernel/sys_ni.c
> mm/mprotect.c
> tools/include/uapi/asm-generic/unistd.h
> tools/perf/arch/powerpc/entry/syscalls/syscall.tbl
> tools/perf/arch/x86/entry/syscalls/syscall_64.tbl
> tools/perf/builtin-trace.c
> tools/testing/selftests/x86/protection_keys.c
> 
> Despite being used on several archs, the only documentation for it
> is inside the x86 directory, as it seems that this is not
> arch-specific.
> 
> Perhaps the file should, instead, be moved to another book.

I guess the best is to have this inside the core-api book.

Patch enclosed.

Regards,
Mauro


[PATCH] docs: move protection-keys.rst to the core-api book

This document is used by multiple architectures:

$ echo $(git grep -l  pkey_mprotect arch|cut -d'/' -f 2|sort|uniq)
alpha arm arm64 ia64 m68k microblaze mips parisc powerpc s390 sh sparc 
x86 xtensa

So, let's move it to the core book and adjust the links to it
accordingly.

Signed-off-by: Mauro Carvalho Chehab 

diff --git a/Documentation/core-api/index.rst b/Documentation/core-api/index.rst
index ee1bb8983a88..2466a4c51031 100644
--- a/Documentation/core-api/index.rst
+++ b/Documentation/core-api/index.rst
@@ -34,6 +34,7 @@ Core utilities
timekeeping
boot-time-mm
memory-hotplug
+   protection-keys
 
 
 Interfaces for kernel debugging
diff --git a/Documentation/x86/protection-keys.rst 
b/Documentation/core-api/protection-keys.rst
similarity index 100%
rename from Documentation/x86/protection-keys.rst
rename to Documentation/core-api/protection-keys.rst
diff --git a/Documentation/x86/index.rst b/Documentation/x86/index.rst
index ae36fc5fc649..f2de1b2d3ac7 100644
--- a/Documentation/x86/index.rst
+++ b/Documentation/x86/index.rst
@@ -19,7 +19,6 @@ x86-specific Documentation
tlb
mtrr
pat
-   protection-keys
intel_mpx
amd-memory-encryption
pti
diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig
index 8c1c636308c8..3b795a0cab62 100644
--- a/arch/powerpc/Kconfig
+++ b/arch/powerpc/Kconfig
@@ -898,7 +898,7 @@ config PPC_MEM_KEYS
  page-based protections, but without requiring modification of the
  page tables when an application changes protection domains.
 
- For details, see Documentation/vm/protection-keys.rst
+ For details, see Documentation/core-api/protection-keys.rst
 
  If unsure, say y.
 
diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
index 2bbbd4d1ba31..d87d53fcd261 100644
--- a/arch/x86/Kconfig
+++ b/arch/x86/Kconfig
@@ -1911,7 +1911,7 @@ config X86_INTEL_MEMORY_PROTECTION_KEYS
  page-based protections, but without requiring modification of the
  page tables when an application changes protection domains.
 
- For details, see Documentation/x86/protection-keys.txt
+ For details, see Documentation/core-api/protection-keys.rst
 
  If unsure, say y.
 
diff --git a/tools/testing/selftests/x86/protection_keys.c 
b/tools/testing/selftests/x86/protection_keys.c
index 5d546dcdbc80..480995bceefa 100644
--- a/tools/testing/selftests/x86/protection_keys.c
+++ b/tools/testing/selftests/x86/protection_keys.c
@@ -1,6 

Re: [PATCH 22/22] docs: fix broken documentation links

2019-06-04 Thread Mauro Carvalho Chehab
Em Mon, 3 Jun 2019 09:34:15 +0200
Christophe Leroy  escreveu:

> Le 30/05/2019 à 01:23, Mauro Carvalho Chehab a écrit :
> > Mostly due to x86 and acpi conversion, several documentation
> > links are still pointing to the old file. Fix them.
> > 
> > Signed-off-by: Mauro Carvalho Chehab 
> > ---
> >   Documentation/acpi/dsd/leds.txt  |  2 +-
> >   Documentation/admin-guide/kernel-parameters.rst  |  6 +++---
> >   Documentation/admin-guide/kernel-parameters.txt  | 16 
> >   Documentation/admin-guide/ras.rst|  2 +-
> >   .../devicetree/bindings/net/fsl-enetc.txt|  7 +++
> >   .../bindings/pci/amlogic,meson-pcie.txt  |  2 +-
> >   .../bindings/regulator/qcom,rpmh-regulator.txt   |  2 +-
> >   Documentation/devicetree/booting-without-of.txt  |  2 +-
> >   Documentation/driver-api/gpio/board.rst  |  2 +-
> >   Documentation/driver-api/gpio/consumer.rst   |  2 +-
> >   .../firmware-guide/acpi/enumeration.rst  |  2 +-
> >   .../firmware-guide/acpi/method-tracing.rst   |  2 +-
> >   Documentation/i2c/instantiating-devices  |  2 +-
> >   Documentation/sysctl/kernel.txt  |  4 ++--
> >   .../translations/it_IT/process/howto.rst |  2 +-
> >   .../it_IT/process/stable-kernel-rules.rst|  4 ++--
> >   .../translations/zh_CN/process/4.Coding.rst  |  2 +-
> >   Documentation/x86/x86_64/5level-paging.rst   |  2 +-
> >   Documentation/x86/x86_64/boot-options.rst|  4 ++--
> >   .../x86/x86_64/fake-numa-for-cpusets.rst |  2 +-
> >   MAINTAINERS  |  6 +++---
> >   arch/arm/Kconfig |  2 +-
> >   arch/arm64/kernel/kexec_image.c  |  2 +-
> >   arch/powerpc/Kconfig |  2 +-
> >   arch/x86/Kconfig | 16 
> >   arch/x86/Kconfig.debug   |  2 +-
> >   arch/x86/boot/header.S   |  2 +-
> >   arch/x86/entry/entry_64.S|  2 +-
> >   arch/x86/include/asm/bootparam_utils.h   |  2 +-
> >   arch/x86/include/asm/page_64_types.h |  2 +-
> >   arch/x86/include/asm/pgtable_64_types.h  |  2 +-
> >   arch/x86/kernel/cpu/microcode/amd.c  |  2 +-
> >   arch/x86/kernel/kexec-bzimage64.c|  2 +-
> >   arch/x86/kernel/pci-dma.c|  2 +-
> >   arch/x86/mm/tlb.c|  2 +-
> >   arch/x86/platform/pvh/enlighten.c|  2 +-
> >   drivers/acpi/Kconfig | 10 +-
> >   drivers/net/ethernet/faraday/ftgmac100.c |  2 +-
> >   .../fieldbus/Documentation/fieldbus_dev.txt  |  4 ++--
> >   drivers/vhost/vhost.c|  2 +-
> >   include/acpi/acpi_drivers.h  |  2 +-
> >   include/linux/fs_context.h   |  2 +-
> >   include/linux/lsm_hooks.h|  2 +-
> >   mm/Kconfig   |  2 +-
> >   security/Kconfig |  2 +-
> >   tools/include/linux/err.h|  2 +-
> >   tools/objtool/Documentation/stack-validation.txt |  4 ++--
> >   tools/testing/selftests/x86/protection_keys.c|  2 +-
> >   48 files changed, 77 insertions(+), 78 deletions(-)  
> 
> [...]
> 
> > diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig
> > index 8c1c636308c8..e868d2bd48b8 100644
> > --- a/arch/powerpc/Kconfig
> > +++ b/arch/powerpc/Kconfig
> > @@ -898,7 +898,7 @@ config PPC_MEM_KEYS
> >   page-based protections, but without requiring modification of the
> >   page tables when an application changes protection domains.
> >   
> > - For details, see Documentation/vm/protection-keys.rst
> > + For details, see Documentation/x86/protection-keys.rst  
> 
> It looks strange to reference an x86 file, for powerpc arch.

Indeed. Yet, seeking for the API documented there:

 $ git grep -l pkey_mprotect
Documentation/x86/protection-keys.rst
arch/alpha/kernel/syscalls/syscall.tbl
arch/arm/tools/syscall.tbl
arch/arm64/include/asm/unistd32.h
arch/ia64/kernel/syscalls/syscall.tbl
arch/m68k/kernel/syscalls/syscall.tbl
arch/microblaze/kernel/syscalls/syscall.tbl
arch/mips/kernel/syscalls/syscall_n32.tbl
arch/mips/kernel/syscalls/syscall_n64.tbl
arch/mips/kernel/syscalls/syscall_o32.tbl
arch/parisc/kernel/syscalls/syscall.tbl
arch/powerpc/kernel/syscalls/syscall.tbl
arch/s390/kernel/syscalls/syscall.

Re: [PATCH 09/22] docs: mark orphan documents as such

2019-06-04 Thread Mauro Carvalho Chehab
Em Mon, 3 Jun 2019 09:32:54 +0200
Christophe Leroy  escreveu:

> Le 30/05/2019 à 01:23, Mauro Carvalho Chehab a écrit :
> > Sphinx doesn't like orphan documents:
> > 
> >  Documentation/accelerators/ocxl.rst: WARNING: document isn't included 
> > in any toctree
> >  Documentation/arm/stm32/overview.rst: WARNING: document isn't included 
> > in any toctree
> >  Documentation/arm/stm32/stm32f429-overview.rst: WARNING: document 
> > isn't included in any toctree
> >  Documentation/arm/stm32/stm32f746-overview.rst: WARNING: document 
> > isn't included in any toctree
> >  Documentation/arm/stm32/stm32f769-overview.rst: WARNING: document 
> > isn't included in any toctree
> >  Documentation/arm/stm32/stm32h743-overview.rst: WARNING: document 
> > isn't included in any toctree
> >  Documentation/arm/stm32/stm32mp157-overview.rst: WARNING: document 
> > isn't included in any toctree
> >  Documentation/gpu/msm-crash-dump.rst: WARNING: document isn't included 
> > in any toctree
> >  Documentation/interconnect/interconnect.rst: WARNING: document isn't 
> > included in any toctree
> >  Documentation/laptops/lg-laptop.rst: WARNING: document isn't included 
> > in any toctree
> >  Documentation/powerpc/isa-versions.rst: WARNING: document isn't 
> > included in any toctree
> >  Documentation/virtual/kvm/amd-memory-encryption.rst: WARNING: document 
> > isn't included in any toctree
> >  Documentation/virtual/kvm/vcpu-requests.rst: WARNING: document isn't 
> > included in any toctree
> > 
> > So, while they aren't on any toctree, add :orphan: to them, in order
> > to silent this warning.  
> 
> Are those files really not meant to be included in a toctree ?
> 
> Shouldn't we include them in the relevant toctree instead of just 
> shutting up Sphinx warnings ?

This is a good point. My understanding is that those orphaned docs
are there for two reasons:

1) someone created a new document as .rst but there's no index.rst file yet,
as there are lots of other documents already there not converted. That's
the case, for example, of the ones under Documentation/arm;

2) They're part of an undergoing effort of converting stuff to ReST.
One opted to keep it orphaned temporarily in order to avoid merge
conflicts.

That's said, I have myself a big (/86 patches and growing) series
with do a huge step on txt->rst conversion (it covers a significant
amount of documentation). On this series, I'm removing the orphaned
tags for several files (including, for example, those at Documentation/arm).

Yet, it is a lot easier to see if such series is not introducing
warnings regressions if we first address those.

It should be notice that discovering the orphaned files should be as
simple as:

git grep -l ":orphan:" Documentation

> 
> Christophe
> 
> > 
> > Signed-off-by: Mauro Carvalho Chehab 
> > ---
> >   Documentation/accelerators/ocxl.rst | 2 ++
> >   Documentation/arm/stm32/overview.rst| 2 ++
> >   Documentation/arm/stm32/stm32f429-overview.rst  | 2 ++
> >   Documentation/arm/stm32/stm32f746-overview.rst  | 2 ++
> >   Documentation/arm/stm32/stm32f769-overview.rst  | 2 ++
> >   Documentation/arm/stm32/stm32h743-overview.rst  | 2 ++
> >   Documentation/arm/stm32/stm32mp157-overview.rst | 2 ++
> >   Documentation/gpu/msm-crash-dump.rst| 2 ++
> >   Documentation/interconnect/interconnect.rst | 2 ++
> >   Documentation/laptops/lg-laptop.rst | 2 ++
> >   Documentation/powerpc/isa-versions.rst  | 2 ++
> >   Documentation/virtual/kvm/amd-memory-encryption.rst | 2 ++
> >   Documentation/virtual/kvm/vcpu-requests.rst | 2 ++
> >   13 files changed, 26 insertions(+)
> > 
> > diff --git a/Documentation/accelerators/ocxl.rst 
> > b/Documentation/accelerators/ocxl.rst
> > index 14cefc020e2d..b1cea19a90f5 100644
> > --- a/Documentation/accelerators/ocxl.rst
> > +++ b/Documentation/accelerators/ocxl.rst
> > @@ -1,3 +1,5 @@
> > +:orphan:
> > +
> >   
> >   OpenCAPI (Open Coherent Accelerator Processor Interface)
> >   
> > diff --git a/Documentation/arm/stm32/overview.rst 
> > b/Documentation/arm/stm32/overview.rst
> > index 85cfc8410798..f7e734153860 100644
> > --- a/Documentation/arm/stm32/overview.rst
> > +++ b/Documentation/arm/stm32/overview.rst
> > @@ -1,3 +1,5 @@
> > +:orphan:
> > +
> >   

[PATCH 22/22] docs: fix broken documentation links

2019-05-29 Thread Mauro Carvalho Chehab
Mostly due to x86 and acpi conversion, several documentation
links are still pointing to the old file. Fix them.

Signed-off-by: Mauro Carvalho Chehab 
---
 Documentation/acpi/dsd/leds.txt  |  2 +-
 Documentation/admin-guide/kernel-parameters.rst  |  6 +++---
 Documentation/admin-guide/kernel-parameters.txt  | 16 
 Documentation/admin-guide/ras.rst|  2 +-
 .../devicetree/bindings/net/fsl-enetc.txt|  7 +++
 .../bindings/pci/amlogic,meson-pcie.txt  |  2 +-
 .../bindings/regulator/qcom,rpmh-regulator.txt   |  2 +-
 Documentation/devicetree/booting-without-of.txt  |  2 +-
 Documentation/driver-api/gpio/board.rst  |  2 +-
 Documentation/driver-api/gpio/consumer.rst   |  2 +-
 .../firmware-guide/acpi/enumeration.rst  |  2 +-
 .../firmware-guide/acpi/method-tracing.rst   |  2 +-
 Documentation/i2c/instantiating-devices  |  2 +-
 Documentation/sysctl/kernel.txt  |  4 ++--
 .../translations/it_IT/process/howto.rst |  2 +-
 .../it_IT/process/stable-kernel-rules.rst|  4 ++--
 .../translations/zh_CN/process/4.Coding.rst  |  2 +-
 Documentation/x86/x86_64/5level-paging.rst   |  2 +-
 Documentation/x86/x86_64/boot-options.rst|  4 ++--
 .../x86/x86_64/fake-numa-for-cpusets.rst |  2 +-
 MAINTAINERS  |  6 +++---
 arch/arm/Kconfig |  2 +-
 arch/arm64/kernel/kexec_image.c  |  2 +-
 arch/powerpc/Kconfig |  2 +-
 arch/x86/Kconfig | 16 
 arch/x86/Kconfig.debug   |  2 +-
 arch/x86/boot/header.S   |  2 +-
 arch/x86/entry/entry_64.S|  2 +-
 arch/x86/include/asm/bootparam_utils.h   |  2 +-
 arch/x86/include/asm/page_64_types.h |  2 +-
 arch/x86/include/asm/pgtable_64_types.h  |  2 +-
 arch/x86/kernel/cpu/microcode/amd.c  |  2 +-
 arch/x86/kernel/kexec-bzimage64.c|  2 +-
 arch/x86/kernel/pci-dma.c|  2 +-
 arch/x86/mm/tlb.c|  2 +-
 arch/x86/platform/pvh/enlighten.c|  2 +-
 drivers/acpi/Kconfig | 10 +-
 drivers/net/ethernet/faraday/ftgmac100.c |  2 +-
 .../fieldbus/Documentation/fieldbus_dev.txt  |  4 ++--
 drivers/vhost/vhost.c|  2 +-
 include/acpi/acpi_drivers.h  |  2 +-
 include/linux/fs_context.h   |  2 +-
 include/linux/lsm_hooks.h|  2 +-
 mm/Kconfig   |  2 +-
 security/Kconfig |  2 +-
 tools/include/linux/err.h|  2 +-
 tools/objtool/Documentation/stack-validation.txt |  4 ++--
 tools/testing/selftests/x86/protection_keys.c|  2 +-
 48 files changed, 77 insertions(+), 78 deletions(-)

diff --git a/Documentation/acpi/dsd/leds.txt b/Documentation/acpi/dsd/leds.txt
index 81a63af42ed2..cc58b1a574c5 100644
--- a/Documentation/acpi/dsd/leds.txt
+++ b/Documentation/acpi/dsd/leds.txt
@@ -96,4 +96,4 @@ where
 
http://www.uefi.org/sites/default/files/resources/_DSD-hierarchical-data-extension-UUID-v1.1.pdf>,
 referenced 2019-02-21.
 
-[7] Documentation/acpi/dsd/data-node-reference.txt
+[7] Documentation/firmware-guide/acpi/dsd/data-node-references.rst
diff --git a/Documentation/admin-guide/kernel-parameters.rst 
b/Documentation/admin-guide/kernel-parameters.rst
index 0124980dca2d..8d3273e32eb1 100644
--- a/Documentation/admin-guide/kernel-parameters.rst
+++ b/Documentation/admin-guide/kernel-parameters.rst
@@ -167,7 +167,7 @@ parameter is applicable::
X86-32  X86-32, aka i386 architecture is enabled.
X86-64  X86-64 architecture is enabled.
More X86-64 boot options can be found in
-   Documentation/x86/x86_64/boot-options.txt .
+   Documentation/x86/x86_64/boot-options.rst.
X86 Either 32-bit or 64-bit x86 (same as X86-32+X86-64)
X86_UV  SGI UV support is enabled.
XEN Xen support is enabled
@@ -181,10 +181,10 @@ In addition, the following text indicates that the 
option::
 Parameters denoted with BOOT are actually interpreted by the boot
 loader, and have no meaning to the kernel directly.
 Do not modify the syntax of boot loader parameters without extreme
-need or coordination with .
+need or coordination with .
 
 There are also arch-specific kernel-parameters not documented here.
-See for example .
+See for example .
 
 Note that ALL kernel parameters listed below are CASE SENSITIVE, and that
 a trailing = on the name of any parameter states that that parameter will
diff --git a/Documentation/admin-guide/kernel-parameters.txt 
b/Documentation/admin-guide/kernel-parameters.txt
in

  1   2   3   >