Re: introduce list_get_first/last (Was: [PATCH 3/6] gfs2: simplify current_tail() via list_last_entry_or_null())

2013-11-17 Thread Jeff Liu
Hi Oleg, Sorry for my late response! On 11/16/2013 01:12 AM, Oleg Nesterov wrote: > On 11/15, Oleg Nesterov wrote: >> >> But probably list_last_entry() makes sense in the "else" branch, >> athough this is minor. >> >> >> Off-topic. Not sure this really makes sense, but I was thinking about >>

Re: introduce list_get_first/last (Was: [PATCH 3/6] gfs2: simplify current_tail() via list_last_entry_or_null())

2013-11-17 Thread Jeff Liu
Hi Oleg, Sorry for my late response! On 11/16/2013 01:12 AM, Oleg Nesterov wrote: On 11/15, Oleg Nesterov wrote: But probably list_last_entry() makes sense in the else branch, athough this is minor. Off-topic. Not sure this really makes sense, but I was thinking about

introduce list_get_first/last (Was: [PATCH 3/6] gfs2: simplify current_tail() via list_last_entry_or_null())

2013-11-15 Thread Oleg Nesterov
On 11/15, Oleg Nesterov wrote: > > But probably list_last_entry() makes sense in the "else" branch, > athough this is minor. > > > Off-topic. Not sure this really makes sense, but I was thinking about > > list_get_first(pos, head, member) \ > ((pos) =

introduce list_get_first/last (Was: [PATCH 3/6] gfs2: simplify current_tail() via list_last_entry_or_null())

2013-11-15 Thread Oleg Nesterov
On 11/15, Oleg Nesterov wrote: But probably list_last_entry() makes sense in the else branch, athough this is minor. Off-topic. Not sure this really makes sense, but I was thinking about list_get_first(pos, head, member) \ ((pos) = list_first_entry(head,