Click here to Skip to main content
11,704,107 members (49,528 online)

Welcome to the Lounge

   

For lazing about and discussing anything in a software developer's life that takes your fancy except programming questions.

Technical discussions are encouraged, but click here to ask your programming question.

The Lounge is rated PG. If you're about to post something you wouldn't want your kid sister to read then don't post it. No flame wars, no abusive conduct, no programming questions and please don't post ads.
 
GeneralHow to use this structurel function and return struct fuction ah? Pin
Venkateshkishore4-Jan-13 3:28
memberVenkateshkishore4-Jan-13 3:28 
Hi ,
In this following code used for struct function also passed one parameter and one structure.why used this type of struct function and advantages.
struct clk *clk_get(struct device *dev, const char *id)
{
struct clk *clk;

list_for_each_entry(clk, &clocks, node) {
if (strcmp(id, clk->name) == 0)
return clk;
if (clk->function && (dev == clk->dev) && strcmp(id, clk->function) == 0)
return clk;
}

return ERR_PTR(-ENOENT);
}
EXPORT_SYMBOL(clk_get);
thanks by,
venkat.
GeneralRe: How to use this structurel function and return struct fuction ah? Pin
Dalek Dave4-Jan-13 3:37
memberDalek Dave4-Jan-13 3:37 
GeneralRe: How to use this structurel function and return struct fuction ah? Pin
Simon_Whale4-Jan-13 3:38
memberSimon_Whale4-Jan-13 3:38 
GeneralRe: How to use this structurel function and return struct fuction ah? Pin
OriginalGriff4-Jan-13 3:45
mvpOriginalGriff4-Jan-13 3:45 
GeneralRe: How to use this structurel function and return struct fuction ah? Pin
Stewart Judson4-Jan-13 3:57
memberStewart Judson4-Jan-13 3:57 
GeneralRe: How to use this structurel function and return struct fuction ah? Pin
Mike Mullikin4-Jan-13 4:33
memberMike Mullikin4-Jan-13 4:33 
GeneralRe: How to use this structurel function and return struct fuction ah? Pin
Gary R. Wheeler4-Jan-13 10:01
memberGary R. Wheeler4-Jan-13 10:01 
GeneralRe: How to use this structurel function and return struct fuction ah? Pin
OriginalGriff4-Jan-13 4:48
mvpOriginalGriff4-Jan-13 4:48 
GeneralRe: How to use this structurel function and return struct fuction ah? Pin
Pete O'Hanlon4-Jan-13 4:04
protectorPete O'Hanlon4-Jan-13 4:04 
GeneralRe: How to use this structurel function and return struct fuction ah? Pin
The Reincarnation4-Jan-13 4:12
memberThe Reincarnation4-Jan-13 4:12 
GeneralRe: How to use this structurel function and return struct fuction ah? Pin
Mike Hankey4-Jan-13 4:24
memberMike Hankey4-Jan-13 4:24 
GeneralRe: How to use this structurel function and return struct fuction ah? Pin
Big Daddy Farang4-Jan-13 4:41
memberBig Daddy Farang4-Jan-13 4:41 
GeneralRe: How to use this structurel function and return struct fuction ah? Pin
BillWoodruff4-Jan-13 9:12
memberBillWoodruff4-Jan-13 9:12 
GeneralRe: How to use this structurel function and return struct fuction ah? Pin
Gary R. Wheeler4-Jan-13 10:03
memberGary R. Wheeler4-Jan-13 10:03 
GeneralRe: How to use this structurel function and return struct fuction ah? Pin
wizardzz4-Jan-13 4:42
memberwizardzz4-Jan-13 4:42 
GeneralRe: How to use this structurel function and return struct fuction ah? Pin
djj554-Jan-13 4:47
memberdjj554-Jan-13 4:47 
GeneralRe: How to use this structurel function and return struct fuction ah? Pin
wizardzz4-Jan-13 4:50
memberwizardzz4-Jan-13 4:50 
GeneralRe: How to use this structurel function and return struct fuction ah? Pin
John Simmons / outlaw programmer4-Jan-13 5:20
mvpJohn Simmons / outlaw programmer4-Jan-13 5:20 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.


Advertise | Privacy | Mobile
Web04 | 2.8.150819.1 | Last Updated 28 Aug 2015
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid