linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: b32955@freescale.com (Huang Shijie)
To: linux-arm-kernel@lists.infradead.org
Subject: reply: [PATCH v5 1/3] ARM: mxs: add GPMI-NFC support for imx23/imx28
Date: Fri, 1 Jul 2011 16:57:40 +0800	[thread overview]
Message-ID: <4E0D8C04.6010409@freescale.com> (raw)
In-Reply-To: <201107010029.51965.arnd@arndb.de>

hi;
> On Thursday 30 June 2011 18:12:27 Huang Shijie-B32955 wrote:
>> I think gpmi-nfc is much better then gpmi-nand or gpmi-flash.
> Then how do you want to name the near field communication drivers?
>
what's meaning of "near field communication" ?

>>> I know that you didn't start this pattern, but I find these macros
>>> extremely annoying. It obscures the use of the macros with the
>>> string concatenation and the macro names are way too generic
>>> for something platform specific. If people think it's a good idea
>>> to have these, please submit a patch to add macros (without the
>>> string concatenation) into include/linux/ioport.h.
>>> Until then, better spell out the resources.
>> ==============================================
>> I ever tried several methods,  but  I can not find a better method to
>> replace the current method.
>>
>> It's annoying, but it really saves some lines.
> It would save more lines if you introduce the macros globally and
> convert all existing resource definitions ;-)
The origin code did not use any macros.
Some one suggested me to use macros.
So i used the macros.

Do i have to drop the macros?



> Making code shorter is usually a good idea, but not when it conflicts
> with readability. Adding custom macros that do string concatenation
> is such a case.
>
>>> When adding new infrastructure, always keep in mind how you want it to look
>>> after the device tree conversion. The partitions and min/max_* are easily covered
>>> with that, but the init/exit function pointers are somewhat problematic.
>>> Fortunately, you don't really require these functions for this driver. The _exit
>>> function is completely unused, so just get rid of it.
>> ===================================================
>> I am reluctant to remove it, I am not sure whether I will use the _exit() in future.
>> But, yes, it can be removed now.
> As a rule, you should never introduce infrastructure just because you might
> need it in the future but don't know if you will really need it.
thanks. I will remove it in next version.

> This is even more important for the actual driver, as I mentioned in my other
> mail. You have a hardware abstraction layer, but only one variant of the hardware
> posted along with the driver. Without seeing different hardware, how should
> anyone be able to tell whether the abstraction is really needed or if it's the
> correct abstraction?
Best Regards
Huang Shijie
> 	Arnd
>

  parent reply	other threads:[~2011-07-01  8:57 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-30 16:12 reply: [PATCH v5 1/3] ARM: mxs: add GPMI-NFC support for imx23/imx28 Huang Shijie-B32955
2011-06-30 22:29 ` Arnd Bergmann
2011-07-01  6:44   ` Uwe Kleine-König
2011-07-01  8:57   ` Huang Shijie [this message]
2011-07-01  9:09     ` Arnd Bergmann
2011-07-07  8:56       ` Huang Shijie
2011-07-07 15:57         ` Arnd Bergmann
2011-07-07 20:48           ` reply: [PATCH v5 1/3] ARM: mxs: add GPMI-NFC support for?imx23/imx28 Uwe Kleine-König
2011-07-07 21:04             ` Arnd Bergmann
2011-07-11 14:40               ` [PATCH] new helper to define common struct resource constructs Uwe Kleine-König
2011-07-11 15:03                 ` [PATCH] ARM: mxc: use new helpers to define common struct resource entries Uwe Kleine-König
2011-07-12 13:29                 ` [PATCH] new helper to define common struct resource constructs Arnd Bergmann
2011-07-12 17:13                   ` H Hartley Sweeten
2011-07-12 18:31                     ` [PATCH v2] " Uwe Kleine-König
2011-07-13 21:18                   ` [PATCH] " Andrew Morton
2011-07-13 21:42                     ` Arnd Bergmann
2011-07-13 22:15                       ` H Hartley Sweeten
2011-07-14  8:11                     ` [PATCH v3] " Uwe Kleine-König
2011-07-14 11:34                       ` Lothar Waßmann
2011-07-01 14:52     ` reply: [PATCH v5 1/3] ARM: mxs: add GPMI-NFC support for imx23/imx28 Arnd Bergmann

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4E0D8C04.6010409@freescale.com \
    --to=b32955@freescale.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).