Date: Mon, 14 Feb 2011 09:24:36 -0500 From: John Baldwin <jhb@freebsd.org> To: freebsd-current@freebsd.org Cc: Matthew Fleming <mdf356@gmail.com> Subject: Re: acpi_resource bug? Message-ID: <201102140924.36531.jhb@freebsd.org> In-Reply-To: <AANLkTi=C31iGJMonj7E3DGLWhx0cSKQR=b7ZHTv9CdmA@mail.gmail.com> References: <AANLkTi=C31iGJMonj7E3DGLWhx0cSKQR=b7ZHTv9CdmA@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sunday, February 13, 2011 2:46:07 pm Matthew Fleming wrote:
> I'm not very familiar with the acpi code, but we have seen an
> intermittent issue on boot:
>
> 1) should the length of the bcopy() be changed to either respect
> res->Length or the actual length of the ACPI_RESOURCE_DATA for the
> type?
It should just use res->Length:
Index: acpi_resource.c
===================================================================
--- acpi_resource.c (revision 218554)
+++ acpi_resource.c (working copy)
@@ -82,7 +82,7 @@ acpi_lookup_irq_handler(ACPI_RESOURCE *res, void *
req->found = 1;
KASSERT(irq == rman_get_start(req->res),
("IRQ resources do not match"));
- bcopy(res, req->acpi_res, sizeof(ACPI_RESOURCE));
+ bcopy(res, req->acpi_res, res->Length);
return (AE_CTRL_TERMINATE);
}
return (AE_OK);
--
John Baldwin
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201102140924.36531.jhb>
