> From: Christophe =?ISO-8859-1?Q?Sta=EFesse?= <chas...@skynet.be>
> 
> Hello :-)
> 
> Here are the diff -u. I've used the 5.0-RELEASE sys.tar.gz to compile
> the kernel.
> 
> dsdt.c : aml_evalexpr now operates with 64-bit unsigned integers as it
> should. (quick hack, not throughoutly tested).   
> 
> --- dsdt.c.old        2012-03-06 10:28:54.000000000 +0100
> +++ dsdt.c    2012-03-06 11:04:15.000000000 +0100
> @@ -63,7 +63,7 @@
>                           const void *);
>  
>  u_int64_t            aml_convradix(u_int64_t, int, int);
> -int64_t                      aml_evalexpr(int64_t, int64_t, int);
> +u_int64_t            aml_evalexpr(u_int64_t, u_int64_t, int);
>  int                  aml_lsb(u_int64_t);
>  int                  aml_msb(u_int64_t);
>  
> @@ -1099,10 +1099,10 @@
>  }
>  
>  /* Evaluate Math operands */
> -int64_t
> -aml_evalexpr(int64_t lhs, int64_t rhs, int opcode)
> +u_int64_t
> +aml_evalexpr(u_int64_t lhs, u_int64_t rhs, int opcode)
>  {
> -     int64_t res = 0;
> +     u_int64_t res = 0;
>  
>       switch (opcode) {
>               /* Math operations */

I've committed this diff.  It seems the acpi code is totally confused
about the signedness of its integers.

> Alternatively, a more general way to remove the superfluous backslash is
> to make it directly in aml_searchname but that doesn't seem to make any
> difference in my case: 
> 
> --- dsdt.c.old        2012-03-06 10:28:54.000000000 +0100
> +++ dsdt.c    2012-03-06 11:05:01.000000000 +0100
> @@ -4085,7 +4085,7 @@
>       int   i;
>  
>       dnprintf(25,"Searchname: %s:%s = ", aml_nodename(root), vname);
> -     if (*name == AMLOP_ROOTCHAR) {
> +     while (*name == AMLOP_ROOTCHAR) {
>               root = &aml_root;
>               name++;
>       }

I think this diff makes more sense.  From the relevant section of the
document it isn't clear if double slashes are allowed.  I'd say not,
but the example of the ECDT table shows a string with a double slash.
That's probably a mistake, but I can't see a downside of interpreting
multiple slashes as a single slash here.

Do unless another developer objects, I'll commit that.

Thanks,

Mark

Reply via email to