Skip to contentSkip to conversation

2.6.21-rc suspend regression: sysfs deadlock

DISCUSSION Oliver Neukum 1 participant 1 message Mar 9, 2007

lore
Share & tools
lore
#0 lore raw

To let you hear the verdict.

Regards
Oliver

---------- Weitergeleitete Nachricht ----------

Subject: Re: 2.6.21-rc suspend regression: sysfs deadlock
Date: Mittwoch, 7. März 2007 19:02
From: Linus Torvalds <[email protected]>
To: Oliver Neukum <[email protected]>
Cc: Dmitry Torokhov <[email protected]>, Hugh Dickins <[email protected]>, Oliver Neukum <[email protected]>, Maneesh Soni <[email protected]>, Greg Kroah-Hartman <[email protected]>, Adrian Bunk <[email protected]>, [email protected]

Quoted 4 lines · Oliver Neukum

The problem also exists with unplugging devices. Drivers get no feedback to tell them when it is safe to free the data structures associated with an attribute.

So you just pointed to *another* data structure that apparently violates the "you MUST use refcounting" rule.

What is it with you people? It's really simple. Data structures must be refcounted if you can reach them two different ways.

If you don't use refcounting, then you'd better make sure that the data can be reached only one way (for example, by *not* exposing it for sysfs).

It really *is* that simple. Read the CodingStyle rules.

Linus

-------------------------------------------------------