Re: [PATCH] Keys: Add possessor permissions to keys

From: Linus Torvalds
Date: Wed Sep 21 2005 - 13:56:53 EST




On Wed, 21 Sep 2005, Andrew Morton wrote:
>
> hrmph. Of course it's a reasonable trick from a performance and
> convenience and resource consumption POV. But it's a new idiom and the
> threshold for new idioms is non-zero. We use it in struct page, but struct
> page is special.

Hmm.. I don't feel it is that new, but maybe that's because I've used that
trick in other places. I think it's pretty common in a "type-safe C" way,
and it should probably be encouraged. A unique pointer type for special
usages, that you can't dereference even by mistake..

But adding a few comments might certainly be worth it. If only to teach
others the trick.

Linus
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/