New ACPI blacklist format

Pawel Jakub Dawidek pjd at FreeBSD.org
Sat May 8 12:30:31 PDT 2004


On Sat, May 08, 2004 at 11:37:26AM -0700, Nate Lawson wrote:
+> > : struct acpi_table_desc {
+> > :     char        *signature;
+> > :     char        *oem_id;
+> > :     char        *oem_table_id;
+> > :     char        *oem_rev_op;
+> > :     char        *oem_revision;
+> > :     char        *creator_id;
+> > :     char        *creator_rev_op;
+> > :     char        *creator_revision;
+> > : };
+> > :
+> > : struct acpi_blacklist {
+> > :     int         quirk;
+> > :     struct      acpi_table_desc *match;
+> > : };
+> > :
+> > : #define ACPI_BROKEN     0x1
+> > :
+> > : static struct acpi_table_desc Abit_BP6[] = {
+> > :     { "FACP", "AWARD", "AWRDACPI", "<=", "30302e31", "", "", "" },
+> > : };
[...]
+> [...] What I meant by compacting was to get a variable
+> number of acpi_table_desc elements in a single blacklist entry without
+> defining a separate static.  Something like this:
+> 
+> static struct acpi_blacklist blacklist[] = {
+>     {
+>         .quirk = ACPI_BROKEN,
+>         {
+>             { "FACP", ... },
+>             { "DSDT", ... }
+>         }
+>     },
+>     {
+>         .quirk = ...
+>     }
+> };
+> 
+> The compiler didn't allow this.

Because you have to do something like this:

struct acpi_blacklist {
	int	quirk;
	struct	acpi_table_desc match[DEFINED_SIZE];
};

-- 
Pawel Jakub Dawidek                       http://www.FreeBSD.org
pjd at FreeBSD.org                           http://garage.freebsd.pl
FreeBSD committer                         Am I Evil? Yes, I Am!
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-arch/attachments/20040508/0827ec23/attachment.bin


More information about the freebsd-arch mailing list