mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Pavel Machek <pavel@ucw.cz>
To: Jeff Garzik <jgarzik@pobox.com>
Cc: Pavel Machek <pavel@ucw.cz>,
	kernel list <linux-kernel@vger.kernel.org>,
	ACPI mailing list <acpi-devel@lists.sourceforge.net>,
	Andrew Grover <andrew.grover@intel.com>
Subject: Re: Code obfuscation in acpi
Date: Sat, 18 Jan 2003 23:39:59 +0100	[thread overview]
Message-ID: <20030118223958.GC21720@atrey.karlin.mff.cuni.cz> (raw)
In-Reply-To: <20030118223210.GA31860@gtf.org>

Hi!

> > #define acpi_driver_data(d)     ((d)->driver_data)
> > 
> > ... very nice for obfuscating code ...
> 
> sysfs-based buses use <foo>_{get,set}_drvdata, which looks exactly the
> same as this here.

I think such wrappers are really bad idea, see for example this: I
thought "what kind of cleverness is going on here,", and it was very
simple in fact.

        else {
                entry->proc_fops = &acpi_thermal_state_fops;
                entry->data = acpi_driver_data(device);
        }


-- 
Casualities in World Trade Center: ~3k dead inside the building,
cryptography in U.S.A. and free speech in Czech Republic.

  reply	other threads:[~2003-01-18 22:31 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-01-18 21:31 Pavel Machek
2003-01-18 22:32 ` Jeff Garzik
2003-01-18 22:39   ` Pavel Machek [this message]
2003-01-20  1:44 ` Rik van Riel

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20030118223958.GC21720@atrey.karlin.mff.cuni.cz \
    --to=pavel@ucw.cz \
    --cc=acpi-devel@lists.sourceforge.net \
    --cc=andrew.grover@intel.com \
    --cc=jgarzik@pobox.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®