lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <200706121253.07395.bjorn.helgaas@hp.com>
Date:	Tue, 12 Jun 2007 12:53:07 -0600
From:	Bjorn Helgaas <bjorn.helgaas@...com>
To:	Andi Drebes <lists-receive@...grammierforen.de>
Cc:	Pavel Machek <pavel@....cz>, Christoph Hellwig <hch@...radead.org>,
	Len Brown <lenb@...nel.org>, kernel-janitors@...ts.osdl.org,
	linux-acpi@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [KJ] [PATCH] drivers/acpi: sizeof/sizeof array size calculations replaced with ARRAY_SIZE

On Tuesday 12 June 2007 12:41:05 pm Andi Drebes wrote:
> First off: sorry for my late answer.
> 
> > I agree the ACPI CA is a nuisance.  But in this case, we're making
> > a mountain out of a molehill.  I suspect that if somebody spent the
> > 15 minutes to make the ARRAY_SIZE patch work in both the Linux ACPI CA
> > and the generic Intel one and license it appropriately, Len would
> > happily apply the patch.
> I hope I got everything right. Here's what I understood so far:
> 
> The ACPI Subsystem in the kernel is derived from intel sources. I searched
> the web for information about that and finally found
> 
> http://www.intel.com/technology/iapc/acpi/downloads.htm
> 
> Is that the right one? So what I would have to do in order to
> "make the ARRAY_SIZE patch work in both the Linux ACPI CA
> and the generic Intel one" is to modify those sources aswell,
> send a patch to Intel and another one back to the
> lkml.

You found the right one.  The ACPI CA in Linux is really the same
as the one from Intel.  Len integrates the Intel one into Linux
periodically.  He uses scripts or something to format it so it looks
more like Linux.

I think Len sometimes takes patches against the "Linux-ized" ACPI CA.
He probably has to apply those by hand to the Intel one, which is
the real "upstream" in this case.  So it might be a bit easier for
him if you generated a diff against the Intel version.  Then it
would show up in Linux, too, in the fullness of time.

In any event, you want to end up with one patch, not two.

You probably would have to add something like:

  #ifndef ARRAY_SIZE
  #define ARRAY_SIZE(x) ...
  #endif

somewhere in the ACPI CA header files.  That way it will work in
non-Linux OSes as well.

Bjorn
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ