login
Header Space

 
 

struct gendisk via request_queue

October 3, 2008 - 11:26am
Submitted by khalil on October 3, 2008 - 11:26am.
Linux

Hi, I need to use the struct gendisk, to get the disk capacity "via" struct request_queue. I know

disk = container_of(queue->kobj.parent, struct gendisk, kobj);

with the old kernel, but with 2.6.26?

Reply

The content of this field is kept private and will not be shown publicly.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd> <b> <quote> <pre> <hr> <br> <p> <img> <blockquote> <font> <tt> <table> <tr> <i>
  • Lines and paragraphs break automatically.
  • Web page addresses and e-mail addresses turn into links automatically.

More information about formatting options

speck-geostationary