All of lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Renninger <trenn@suse.de>
To: Len Brown <lenb@kernel.org>
Cc: linux-kernel <linux-kernel@vger.kernel.org>,
	linux-acpi <linux-acpi@vger.kernel.org>,
	Kay Sievers <kasievers@suse.de>
Subject: Re: [PATCH 1/3] ACPI autoloading - ACPICA adjustance
Date: Tue, 03 Jul 2007 14:23:55 +0200	[thread overview]
Message-ID: <1183465435.16639.131.camel@queen.suse.de> (raw)
In-Reply-To: <200707030358.59031.lenb@kernel.org>

On Tue, 2007-07-03 at 03:58 -0400, Len Brown wrote:
> On Sunday 17 June 2007 16:24, Thomas Renninger wrote:
> > Define standardized HIDs ...
> 
> > Index: linux-2.6.22-rc4/include/acpi/acpi_drivers.h
> > ===================================================================
> > --- linux-2.6.22-rc4.orig/include/acpi/acpi_drivers.h
> > +++ linux-2.6.22-rc4/include/acpi/acpi_drivers.h
> > @@ -34,16 +34,33 @@
> >  #define ACPI_BUS_COMPONENT		0x00010000
> >  #define ACPI_SYSTEM_COMPONENT		0x02000000
> >  
> > -/* _HID definitions */
> > +/*
> > +  _HID definitions
> > +  HIDs starting with 'X' are self defined here and are used for devices where
> > +  a HID does not exist in spec.
> > +  HIDs must conform to (ACPI spec - 6.1.4):
> >  
> > -#define ACPI_POWER_HID			"power_resource"
> > +  Numeric 32-bit compressed EISA type ID are not supported (never seen one as
> > +  an ACPI HID?)
> > +
> > +  A valid PNP ID must be of the form AAA#### where A is an uppercase letter
> > +  and # is a hex digit.
> > +  A valid ACPI ID must be of the form ACPI#### where # is a hex digit.
> > +
> > +  and our self-defined: XAAA#### where A is an uppercase letter and # is a hex
> > +  digit.
> 
> What was the criteria for inventing the XAAA#### format?
> It doesn't comply with the PNP standard format above, since
> it starts with four letters instead of three.
Yes, it still violates the standard, intend was to not do so.
And to stick to the 8/9 bytes.
The X has the same meaning as your suggestion below, starting with LNX,
it should be visible that it is an out of spec, linux only hid.
> 
> I don't think that "XVID0001" will be more meaningful than "video"
> when seen in sysfs...
> 
> > +*/
> > +
> > +#define ACPI_POWER_HID			"XPWR0001"
> >  #define ACPI_PROCESSOR_HID		"ACPI0007"
> > -#define ACPI_SYSTEM_HID			"acpi_system"
> > -#define ACPI_THERMAL_HID		"thermal"
> > -#define ACPI_BUTTON_HID_POWERF		"button_power"
> > -#define ACPI_BUTTON_HID_SLEEPF		"button_sleep"
> > -#define ACPI_VIDEO_HID			"video"
> > -#define ACPI_BAY_HID			"bay"
> > +#define ACPI_SYSTEM_HID			"XSYS0001"
> > +#define ACPI_THERMAL_HID		"XTHM0001"
> > +#define ACPI_BUTTON_HID_POWERF		"XPBT0001"
> > +#define ACPI_BUTTON_HID_SLEEPF		"XSBT0001"
> > +#define ACPI_VIDEO_HID			"XVID0001"
> > +#define ACPI_BAY_HID			"XBAY0001"
> > +
> 
> If the criteria is to stay within an 8 character id length,
> I'd rather spell a word with capital letters, and stick
> in 0's where we don't need more letters:
> 
> POWER000
> SYSTEM00
> THERMAL0
> PWRBTN00
> SLEEPBTN
> VIDEO000
> DRIVEBAY
> 
> Or when we discussed this before, we though about not conflicting
> with a standard (or vendor standard) name by becoming the Linux vendor --
> say using  the "LNX" prefix, and trying to spell something useful
> in the remaining 5 characters. eg.
> 
> LNXPOWER
> LNXSYSTM
> LNXTHERM
> LNXSLPBN
> LNXPWRBN
> LNXVIDEO
> LNXIOBAY

Don't know what is better, the first solution looks nicer...
Just tell me the final suggestion and I redo the patch.

    Thomas

PS: What is your general impression of the patches, will you add the
next series to acpi-test?
Shall I wait for some other patch(es) and then rebase, this one touches
nearly every file in /drivers/acpi/*.c and could end up in some merge
work for me or others.


      reply	other threads:[~2007-07-03 12:23 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-06-17 20:24 [PATCH 1/3] ACPI autoloading - ACPICA adjustance Thomas Renninger
2007-06-17 20:27 ` [PATCH 2/3] ACPI autoloading - Create acpi alias interface Thomas Renninger
2007-06-17 20:24   ` [PATCH 3/3] ACPI autoloading - Create __mod_acpi_device_table symbol for all acpi drivers Thomas Renninger
2007-06-17 22:49     ` Henrique de Moraes Holschuh
2007-06-19 12:53       ` Thomas Renninger
2007-06-19 16:23         ` Mattia Dongili
2007-06-19 21:27         ` Henrique de Moraes Holschuh
2007-07-03  7:11           ` Len Brown
2007-07-03 15:06             ` Henrique de Moraes Holschuh
2007-06-20 17:06     ` Mattia Dongili
2007-06-20 17:47       ` Thomas Renninger
     [not found]         ` <1182361643.28514.708.camel-X8wR35IVlAxolqkO4TVVkw@public.gmane.org>
2007-06-21  4:16           ` Mattia Dongili
2007-06-21  4:16             ` Mattia Dongili
2007-07-03  7:15         ` Len Brown
     [not found]           ` <200707030315.33526.lenb-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2007-07-04  7:33             ` Mattia Dongili
2007-07-04  7:33               ` Mattia Dongili
2007-07-04 10:17               ` Thomas Renninger
2007-06-20 15:52   ` [PATCH 2/3] ACPI autoloading - Create acpi alias interface Mattia Dongili
2007-06-20 17:24     ` Thomas Renninger
2007-07-03  7:58 ` [PATCH 1/3] ACPI autoloading - ACPICA adjustance Len Brown
2007-07-03 12:23   ` Thomas Renninger [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1183465435.16639.131.camel@queen.suse.de \
    --to=trenn@suse.de \
    --cc=kasievers@suse.de \
    --cc=lenb@kernel.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.