lkml.org 
[lkml]   [2011]   [Jan]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH v2] net: add Faraday FTMAC100 10/100 Ethernet driver
Dear Joe,

On Thu, Jan 20, 2011 at 12:41 AM, Joe Perches <joe@perches.com> wrote:
> On Wed, 2011-01-19 at 17:40 +0800, Po-Yu Chuang wrote:
>> Well, TBH, I don't like this style because if I changed the
>> function name, the indentation might need to be adjusted.
>
> No worries.  That could happen using either style.
>
> There's no required style so you can use what you are
> most comfortable doing.  It's not a big deal at all.
>
>> Even worse, I got an infeasible case :-(
>>
>> static struct ftmac100_rxdes *ftmac100_rx_locate_first_segment(
>>                                                              struct ftmac100 *priv)
>>
>> I know my function names are quite long, but I like them to be descriptive.
>> Do you really insist on it?
>
> Here's a common alternative style for this case:
>
> static struct ftmac100_rxdes *
> ftmac100_rx_locate_first_segment(struct ftmac100 *priv)

OK, I see.

One more question: how to deal with this? Add a local variable for the
2nd argument?

ftmac100_set_receive_ring_base(priv,
priv->descs_dma_addr + offsetof(struct ftmac100_descs, rxdes));

best regards,
Po-Yu Chuang
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2011-01-20 06:33    [W:0.129 / U:0.260 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site