Skip to contentSkip to conversation

struct char_device

PATCH Tommy Hallgren 1 participant 1 message May 22, 2001

lore
Share & tools
lore
#0 lore raw

Hi Alexander!

If I'm not entirely mistaken, this:

+ if ((flags & (SLAB_CTOR_VERIFY|SLAB_CTOR_CONSTRUCTOR)) ==
+ SLAB_CTOR_CONSTRUCTOR)
+ {
+ memset(cdev, 0, sizeof(*cdev));
+ sema_init(&cdev->sem, 1);
+ }
+}

could be replaced with this:

+ if ((flags & SLAB_CTOR_CONSTRUCTOR) == SLAB_CTOR_CONSTRUCTOR)
+ {
+ memset(cdev, 0, sizeof(*cdev));
+ sema_init(&cdev->sem, 1);
+ }
+}

Regards, Tommy

__________________________________________________
Do You Yahoo!?
Yahoo! Auctions - buy the things you want at great prices
http://auctions.yahoo.com/