linux-next.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* linux-next: build warning after merge of the leds-lj tree
@ 2024-01-05  6:33 Stephen Rothwell
  2024-01-08  7:47 ` Florian Eckert
  0 siblings, 1 reply; 6+ messages in thread
From: Stephen Rothwell @ 2024-01-05  6:33 UTC (permalink / raw)
  To: Lee Jones
  Cc: Florian Eckert, Linux Kernel Mailing List, Linux Next Mailing List

[-- Attachment #1: Type: text/plain, Size: 587 bytes --]

Hi all,

After merging the leds-lj tree, today's linux-next build (htmldocs)
produced this warning:

Warning: /sys/class/leds/<led>/rx is defined 2 times:  Documentation/ABI/testing/sysfs-class-led-trigger-tty:7  Documentation/ABI/testing/sysfs-class-led-trigger-netdev:49
Warning: /sys/class/leds/<led>/tx is defined 2 times:  Documentation/ABI/testing/sysfs-class-led-trigger-tty:15  Documentation/ABI/testing/sysfs-class-led-trigger-netdev:34

Introduced by commit

  5b755ca677db ("leds: ledtrig-tty: Make rx tx activitate configurable")

-- 
Cheers,
Stephen Rothwell

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: linux-next: build warning after merge of the leds-lj tree
  2024-01-05  6:33 linux-next: build warning after merge of the leds-lj tree Stephen Rothwell
@ 2024-01-08  7:47 ` Florian Eckert
  2024-01-09 11:20   ` Stephen Rothwell
  0 siblings, 1 reply; 6+ messages in thread
From: Florian Eckert @ 2024-01-08  7:47 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Lee Jones, Linux Kernel Mailing List, Linux Next Mailing List

Hello Stephen,

thanks for your hint

On 2024-01-05 07:33, Stephen Rothwell wrote:
> Hi all,
> 
> After merging the leds-lj tree, today's linux-next build (htmldocs)
> produced this warning:
> 
> Warning: /sys/class/leds/<led>/rx is defined 2 times:
> Documentation/ABI/testing/sysfs-class-led-trigger-tty:7
> Documentation/ABI/testing/sysfs-class-led-trigger-netdev:49
> Warning: /sys/class/leds/<led>/tx is defined 2 times:
> Documentation/ABI/testing/sysfs-class-led-trigger-tty:15
> Documentation/ABI/testing/sysfs-class-led-trigger-netdev:34

The behavior of the tty trigger can be controlled via the Rx and Tx 
file.
If a value is set in Rx or Tx, the LED flashes when data is transmitted 
in
this direction. The same behavior is used for the netdev trigger.
I have therefore used the same pattern for the new tty trigger as well.

I didn't know that the names have to be unique!

I'm a bit at a loss as to what to do now. Should I put a prefix "tty_"
in front of the names so that we have "tty_rx", "tty_tx"?

If we do it this way, however, the general question arises as to whether
we do have to use a prefix everywhere! If new triggers are added, then 
the
names for a config file are already used up and anyone who then wants to 
use
the same name for an other trigger with the same config file because it 
describe
the same function must then work with a prefix!

Best regards

Florian

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: linux-next: build warning after merge of the leds-lj tree
  2024-01-08  7:47 ` Florian Eckert
@ 2024-01-09 11:20   ` Stephen Rothwell
  2024-01-25  0:38     ` Stephen Rothwell
  2024-02-08 23:20     ` Jonathan Corbet
  0 siblings, 2 replies; 6+ messages in thread
From: Stephen Rothwell @ 2024-01-09 11:20 UTC (permalink / raw)
  To: Florian Eckert
  Cc: Jonathan Corbet, Lee Jones, Linux Kernel Mailing List,
	Linux Next Mailing List

[-- Attachment #1: Type: text/plain, Size: 1879 bytes --]

Hi Florian,

On Mon, 08 Jan 2024 08:47:07 +0100 Florian Eckert <fe@dev.tdt.de> wrote:
>
> Hello Stephen,
> 
> thanks for your hint
> 
> On 2024-01-05 07:33, Stephen Rothwell wrote:
> > Hi all,
> > 
> > After merging the leds-lj tree, today's linux-next build (htmldocs)
> > produced this warning:
> > 
> > Warning: /sys/class/leds/<led>/rx is defined 2 times:
> > Documentation/ABI/testing/sysfs-class-led-trigger-tty:7
> > Documentation/ABI/testing/sysfs-class-led-trigger-netdev:49
> > Warning: /sys/class/leds/<led>/tx is defined 2 times:
> > Documentation/ABI/testing/sysfs-class-led-trigger-tty:15
> > Documentation/ABI/testing/sysfs-class-led-trigger-netdev:34  
> 
> The behavior of the tty trigger can be controlled via the Rx and Tx file.
> If a value is set in Rx or Tx, the LED flashes when data is transmitted in
> this direction. The same behavior is used for the netdev trigger.
> I have therefore used the same pattern for the new tty trigger as well.
> 
> I didn't know that the names have to be unique!
> 
> I'm a bit at a loss as to what to do now. Should I put a prefix "tty_"
> in front of the names so that we have "tty_rx", "tty_tx"?
> 
> If we do it this way, however, the general question arises as to whether
> we do have to use a prefix everywhere! If new triggers are added, then the
> names for a config file are already used up and anyone who then wants to use
> the same name for an other trigger with the same config file because it describe
> the same function must then work with a prefix!

I think this is only a problem with the documentation system, not the
actual sysfs file naming.  Maybe just adding a uniquifying bit to the
"<led>" part will solve it.  Or maybe we need the tooling to be taught
about placeholders in sysfs names (or maybe there is already a way).

-- 
Cheers,
Stephen Rothwell

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: linux-next: build warning after merge of the leds-lj tree
  2024-01-09 11:20   ` Stephen Rothwell
@ 2024-01-25  0:38     ` Stephen Rothwell
  2024-02-08 23:20     ` Jonathan Corbet
  1 sibling, 0 replies; 6+ messages in thread
From: Stephen Rothwell @ 2024-01-25  0:38 UTC (permalink / raw)
  To: Florian Eckert
  Cc: Jonathan Corbet, Lee Jones, Linux Kernel Mailing List,
	Linux Next Mailing List

[-- Attachment #1: Type: text/plain, Size: 2027 bytes --]

Hi all,

On Tue, 9 Jan 2024 22:20:31 +1100 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
>
> On Mon, 08 Jan 2024 08:47:07 +0100 Florian Eckert <fe@dev.tdt.de> wrote:
> >
> > thanks for your hint
> > 
> > On 2024-01-05 07:33, Stephen Rothwell wrote:  
> > > Hi all,
> > > 
> > > After merging the leds-lj tree, today's linux-next build (htmldocs)
> > > produced this warning:
> > > 
> > > Warning: /sys/class/leds/<led>/rx is defined 2 times: Documentation/ABI/testing/sysfs-class-led-trigger-tty:7 Documentation/ABI/testing/sysfs-class-led-trigger-netdev:49
> > > Warning: /sys/class/leds/<led>/tx is defined 2 times: Documentation/ABI/testing/sysfs-class-led-trigger-tty:15 Documentation/ABI/testing/sysfs-class-led-trigger-netdev:34    
> > 
> > The behavior of the tty trigger can be controlled via the Rx and Tx file.
> > If a value is set in Rx or Tx, the LED flashes when data is transmitted in
> > this direction. The same behavior is used for the netdev trigger.
> > I have therefore used the same pattern for the new tty trigger as well.
> > 
> > I didn't know that the names have to be unique!
> > 
> > I'm a bit at a loss as to what to do now. Should I put a prefix "tty_"
> > in front of the names so that we have "tty_rx", "tty_tx"?
> > 
> > If we do it this way, however, the general question arises as to whether
> > we do have to use a prefix everywhere! If new triggers are added, then the
> > names for a config file are already used up and anyone who then wants to use
> > the same name for an other trigger with the same config file because it describe
> > the same function must then work with a prefix!  
> 
> I think this is only a problem with the documentation system, not the
> actual sysfs file naming.  Maybe just adding a uniquifying bit to the
> "<led>" part will solve it.  Or maybe we need the tooling to be taught
> about placeholders in sysfs names (or maybe there is already a way).

I am still seeing these warnings.

-- 
Cheers,
Stephen Rothwell

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: linux-next: build warning after merge of the leds-lj tree
  2024-01-09 11:20   ` Stephen Rothwell
  2024-01-25  0:38     ` Stephen Rothwell
@ 2024-02-08 23:20     ` Jonathan Corbet
  2024-02-09  8:02       ` Lee Jones
  1 sibling, 1 reply; 6+ messages in thread
From: Jonathan Corbet @ 2024-02-08 23:20 UTC (permalink / raw)
  To: Stephen Rothwell, Florian Eckert
  Cc: Lee Jones, Linux Kernel Mailing List, Linux Next Mailing List

Stephen Rothwell <sfr@canb.auug.org.au> writes:

> Hi Florian,
>
> On Mon, 08 Jan 2024 08:47:07 +0100 Florian Eckert <fe@dev.tdt.de> wrote:
>>
>> Hello Stephen,
>> 
>> thanks for your hint
>> 
>> On 2024-01-05 07:33, Stephen Rothwell wrote:
>> > Hi all,
>> > 
>> > After merging the leds-lj tree, today's linux-next build (htmldocs)
>> > produced this warning:
>> > 
>> > Warning: /sys/class/leds/<led>/rx is defined 2 times:
>> > Documentation/ABI/testing/sysfs-class-led-trigger-tty:7
>> > Documentation/ABI/testing/sysfs-class-led-trigger-netdev:49
>> > Warning: /sys/class/leds/<led>/tx is defined 2 times:
>> > Documentation/ABI/testing/sysfs-class-led-trigger-tty:15
>> > Documentation/ABI/testing/sysfs-class-led-trigger-netdev:34  
>> 
>> The behavior of the tty trigger can be controlled via the Rx and Tx file.
>> If a value is set in Rx or Tx, the LED flashes when data is transmitted in
>> this direction. The same behavior is used for the netdev trigger.
>> I have therefore used the same pattern for the new tty trigger as well.
>> 
>> I didn't know that the names have to be unique!
>> 
>> I'm a bit at a loss as to what to do now. Should I put a prefix "tty_"
>> in front of the names so that we have "tty_rx", "tty_tx"?
>> 
>> If we do it this way, however, the general question arises as to whether
>> we do have to use a prefix everywhere! If new triggers are added, then the
>> names for a config file are already used up and anyone who then wants to use
>> the same name for an other trigger with the same config file because it describe
>> the same function must then work with a prefix!
>
> I think this is only a problem with the documentation system, not the
> actual sysfs file naming.  Maybe just adding a uniquifying bit to the
> "<led>" part will solve it.  Or maybe we need the tooling to be taught
> about placeholders in sysfs names (or maybe there is already a way).

So I finally remembered to look at this when I had a chance to...  yes,
it wants each ABI entry to be unique, and the ones listed here are not.
I *think* the easiest answer is to take a line like:

  What:		/sys/class/leds/<led>/rx

and turn it into something like:

  What:		/sys/class/leds/<netdev-led>/rx

...that makes the warning go away and, I think, conveys the information
just as well.  A bit kludgy, perhaps, but I don't really see anything
else there that could be used to disambiguate the names automatically.

Thanks,

jon

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: linux-next: build warning after merge of the leds-lj tree
  2024-02-08 23:20     ` Jonathan Corbet
@ 2024-02-09  8:02       ` Lee Jones
  0 siblings, 0 replies; 6+ messages in thread
From: Lee Jones @ 2024-02-09  8:02 UTC (permalink / raw)
  To: Jonathan Corbet
  Cc: Stephen Rothwell, Florian Eckert, Linux Kernel Mailing List,
	Linux Next Mailing List

On Thu, 08 Feb 2024, Jonathan Corbet wrote:

> Stephen Rothwell <sfr@canb.auug.org.au> writes:
> 
> > Hi Florian,
> >
> > On Mon, 08 Jan 2024 08:47:07 +0100 Florian Eckert <fe@dev.tdt.de> wrote:
> >>
> >> Hello Stephen,
> >> 
> >> thanks for your hint
> >> 
> >> On 2024-01-05 07:33, Stephen Rothwell wrote:
> >> > Hi all,
> >> > 
> >> > After merging the leds-lj tree, today's linux-next build (htmldocs)
> >> > produced this warning:
> >> > 
> >> > Warning: /sys/class/leds/<led>/rx is defined 2 times:
> >> > Documentation/ABI/testing/sysfs-class-led-trigger-tty:7
> >> > Documentation/ABI/testing/sysfs-class-led-trigger-netdev:49
> >> > Warning: /sys/class/leds/<led>/tx is defined 2 times:
> >> > Documentation/ABI/testing/sysfs-class-led-trigger-tty:15
> >> > Documentation/ABI/testing/sysfs-class-led-trigger-netdev:34  
> >> 
> >> The behavior of the tty trigger can be controlled via the Rx and Tx file.
> >> If a value is set in Rx or Tx, the LED flashes when data is transmitted in
> >> this direction. The same behavior is used for the netdev trigger.
> >> I have therefore used the same pattern for the new tty trigger as well.
> >> 
> >> I didn't know that the names have to be unique!
> >> 
> >> I'm a bit at a loss as to what to do now. Should I put a prefix "tty_"
> >> in front of the names so that we have "tty_rx", "tty_tx"?
> >> 
> >> If we do it this way, however, the general question arises as to whether
> >> we do have to use a prefix everywhere! If new triggers are added, then the
> >> names for a config file are already used up and anyone who then wants to use
> >> the same name for an other trigger with the same config file because it describe
> >> the same function must then work with a prefix!
> >
> > I think this is only a problem with the documentation system, not the
> > actual sysfs file naming.  Maybe just adding a uniquifying bit to the
> > "<led>" part will solve it.  Or maybe we need the tooling to be taught
> > about placeholders in sysfs names (or maybe there is already a way).
> 
> So I finally remembered to look at this when I had a chance to...  yes,
> it wants each ABI entry to be unique, and the ones listed here are not.
> I *think* the easiest answer is to take a line like:
> 
>   What:		/sys/class/leds/<led>/rx
> 
> and turn it into something like:
> 
>   What:		/sys/class/leds/<netdev-led>/rx
> 
> ...that makes the warning go away and, I think, conveys the information
> just as well.  A bit kludgy, perhaps, but I don't really see anything
> else there that could be used to disambiguate the names automatically.

Thanks Jon.

Please see:

  https://git.kernel.org/pub/scm/linux/kernel/git/lee/leds.git/commit/?h=for-leds-next&id=4694dcab92cf0e78ff65978888ae14a6373f1ceb

-- 
Lee Jones [李琼斯]

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2024-02-09  8:03 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-01-05  6:33 linux-next: build warning after merge of the leds-lj tree Stephen Rothwell
2024-01-08  7:47 ` Florian Eckert
2024-01-09 11:20   ` Stephen Rothwell
2024-01-25  0:38     ` Stephen Rothwell
2024-02-08 23:20     ` Jonathan Corbet
2024-02-09  8:02       ` Lee Jones

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).