[ltp] Re: [Patch 2/3] ibm-acpi: LED Subsystem integration.

Stefan Schmidt linux-thinkpad@linux-thinkpad.org
Thu, 26 Oct 2006 20:02:26 +0200


--yjwCkqRTi5XZ0JAy
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Hello.

On Thu, 2006-10-26 at 15:00, Shem Multinymous wrote:
> >
> >Indeed. Even if goto is not the right thing on other problems, it can
> >make the code less bloated here.
>=20
> Coming to think of it, there's an even better way.
> Define a static const array containing the LED attributes.
> Then have a static pointer to the next LED to initialize. It starts at
> the beginning of the array, incremented via a loop in module init, and
> decremented in a loop on either init failure or module unload.
> The module init code in tp_smapi.c does exactly that, you can copy the co=
de.

OK, I'll take a look at both, goto and the tp_smapi idea. Let's see
which one I prefer afterwards.

regards
Stefan Schmidt

--yjwCkqRTi5XZ0JAy
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: Digital signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)
Comment: http://www.datenfreihafen.org/contact.html

iD8DBQFFQPgybNSsvd31FmURAnbVAKCV9iHybopLLWOTIvIiCctZmuZT1gCfYNsS
QkhYeNHFzK4cSEDuSeE6+ao=
=r0l9
-----END PGP SIGNATURE-----

--yjwCkqRTi5XZ0JAy--