Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 8 May 2005 02:44:49 -0400
From:      Martin Cracauer <cracauer@cons.org>
To:        freebsd-acpi@freebsd.org
Subject:   Porting code from the Linux ibm-acpi sourceforge package
Message-ID:  <20050508024448.A943@cons.org>

next in thread | raw e-mail | index | archive | help
Hi,

I reinstalled my Thinkpad R40 with FreeBSD-5-stable.  Works very well
except for video corruption on sleep and that I miss some ACPI
functionality I had with the ibm-acpi package under Linux.

More specifically, I would like to port or reimplement some parts of
it, and I would like to start with the code to eject and re-mount the
ultrabay devices.

I have the Linux code in front of me which is showing, for the example
of the basic bay identifier and the eject code:

IBM_HANDLE(bay, root,
           "\\_SB.PCI.IDE.SECN.MAST",   /* 570 */
           "\\_SB.PCI0.IDE0.IDES.IDSM", /* 600e/x, 770e, 770x */
           "\\_SB.PCI0.IDE0.SCND.MSTR", /* all others */
);                                      /* A21e, R30, R31 */
IBM_HANDLE(bay_ej, bay,
           "_EJ3",                 /* 600e/x, A2xm/p, A3x */
           "_EJ0",                 /* all others */
);                                 /* 570,A21e,G4x,R30,R31,R32,R40e,R50e */

Looking at FreeBSD's acpi_asus.c I can easily figure how this is
arranged in FreeBSD, but I am not sure whether I am lacking some glue
here.  Right now the sysctl acpi stuff is not mentioning any of the
IBM-specific variables.

Would these ACPI status variables only show up when I have a module
loaded which is actually using them?

Do I need to "grab" specific variables in advance, or is it sufficient
to just load the IBM equivalent of acpi_asus.c and would that do it
automatically?

Is there hope that I can hack this up without learning ACPI first? It
looks pretty straightforward, am I totally ignorant or is it
realistic?

Last but not least, if I just snarf the strings from the GPL code, I
assume that would make me stay clear of the GPL, would it? I obviously
want to give credit to the authors of that package.

Thanks
	Martin
-- 
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Martin Cracauer <cracauer@cons.org>   http://www.cons.org/cracauer/
 No warranty.    This email is probably produced by one of my cats 
 stepping on the keys. No, I don't have an infinite number of cats.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050508024448.A943>