public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Sekhar Nori <nsekhar@ti.com>
To: "Philip, Avinash" <avinashphilip@ti.com>
Cc: "khilman@deeprootsystems.com" <khilman@deeprootsystems.com>,
	"linux@arm.linux.org.uk" <linux@arm.linux.org.uk>,
	"grant.likely@secretlab.ca" <grant.likely@secretlab.ca>,
	"linus.walleij@linaro.org" <linus.walleij@linaro.org>,
	"linux-arm-kernel@lists.infradead.org" 
	<linux-arm-kernel@lists.infradead.org>,
	"davinci-linux-open-source@linux.davincidsp.com" 
	<davinci-linux-open-source@linux.davincidsp.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 03/11] gpio: davinci: Modify to platform driver
Date: Thu, 13 Jun 2013 13:59:53 +0530	[thread overview]
Message-ID: <51B98301.9090404@ti.com> (raw)
In-Reply-To: <518397C60809E147AF5323E0420B992E3EADA883@DBDE04.ent.ti.com>

On 6/13/2013 1:02 PM, Philip, Avinash wrote:

> With tnetv107x_defconfig build is failing
> 
> arch/arm/mach-davinci/board-tnetv107x-evm.c:282:15: error:
>  'davinci_timer_init' undeclared here (not in a function)
> arch/arm/mach-davinci/board-tnetv107x-evm.c:284:15: error:
>  'davinci_init_late' undeclared here (not in a function)
> make[1]: *** [arch/arm/mach-davinci/board-tnetv107x-evm.o] Error 1
> 
> Following patch fixes the build above breakage

The error you are seeing and the patch you provided below have no
correlation.

> 
> diff --git a/arch/arm/mach-davinci/board-tnetv107x-evm.c b/arch/arm/mach-davinci/board-tnetv107x-evm.c
> index ba79837..4a9c320 100644
> --- a/arch/arm/mach-davinci/board-tnetv107x-evm.c
> +++ b/arch/arm/mach-davinci/board-tnetv107x-evm.c
> @@ -30,6 +30,7 @@
>  #include <asm/mach/arch.h>
>  #include <asm/mach-types.h>
> 
> +#include <mach/common.h>
>  #include <mach/irqs.h>
>  #include <mach/edma.h>
>  #include <mach/mux.h>
> @@ -147,7 +148,7 @@ static struct davinci_nand_pdata nand_config = {
>         .ecc_bits       = 1,
>  };
> 
> -static struct davinci_uart_config serial_config __initconst = {
> +static struct davinci_uart_config serial_config = {
>         .enabled_uarts  = BIT(1),
>  };

You can make this __initdata instead - assuming its okay to have this
memory discarded at init.

> 
> @@ -245,7 +246,7 @@ static struct ti_ssp_data ssp_config = {
>         },
>  };
> 
> -static struct tnetv107x_device_info evm_device_info __initconst = {
> +static struct tnetv107x_device_info evm_device_info = {

Same here. You can make this __initdata.

Please send a formal patch for the errors you have seen.

>         .serial_config          = &serial_config,
>         .mmc_config[1]          = &mmc_config,  /* controller 1 */
>         .nand_config[0]         = &nand_config, /* chip select 0 */
> 
> 
> 
>>
>>>
>>> So I prefer to leave tnetv107x platform for now.
>>
>> I don't think that's acceptable. At least by me.
> 
> I think 2 options are available
> 1. Convert gpio-tnetv107x.c to platform driver. This will help in
> 	removing gpio references in davinci_soc_info structure.
> 2. Remove inline gpio api support and start use gpiolib support.
> 
> I prefer first option. It will help in removing
> <arch/arm/mach-davinci/include/mach/gpio-davinci.h>.

Okay. Can you take this up in this series? I understand you may not have
an tnetv107x board, but at least you can get to a series that builds.

Even if you choose to do just option #2, I am OK. What I really want to
see is inline API gone completely (not just remain largely unused). This
will also help you avoid exposing internal data structures like
davinci_gpio_controller exposed to the whole kernel. The worse part
right now is you have two copies of the same structure exposed globally
from two different include folders.

Thanks,
Sekhar

  reply	other threads:[~2013-06-13  8:30 UTC|newest]

Thread overview: 44+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-22  7:10 [PATCH 00/11] Convert GPIO Davinci to platform driver Philip Avinash
2013-05-22  7:10 ` [PATCH 01/11] ARM: davinci: GPIO: Add platform data structure Philip Avinash
2013-05-30 18:06   ` Linus Walleij
2013-06-11 10:36   ` Sekhar Nori
2013-06-11 11:10     ` Sergei Shtylyov
2013-06-11 12:53     ` Philip, Avinash
2013-05-22  7:10 ` [PATCH 02/11] gpio: davinci: coding style correction Philip Avinash
2013-05-22 12:59   ` Sergei Shtylyov
2013-05-23  6:27     ` Philip, Avinash
2013-05-22 14:40   ` Russell King - ARM Linux
2013-05-23  6:27     ` Philip, Avinash
2013-06-11 11:42   ` Sekhar Nori
2013-05-22  7:10 ` [PATCH 03/11] gpio: davinci: Modify to platform driver Philip Avinash
2013-05-30 18:12   ` Linus Walleij
2013-06-11 11:56   ` Sekhar Nori
2013-06-11 12:55     ` Philip, Avinash
2013-06-12  7:43       ` Sekhar Nori
2013-06-12 12:10         ` Philip, Avinash
2013-06-13  6:17           ` Sekhar Nori
2013-06-13  7:32             ` Philip, Avinash
2013-06-13  8:29               ` Sekhar Nori [this message]
2013-06-13  9:18                 ` Philip, Avinash
2013-05-22  7:10 ` [PATCH 04/11] ARM: davinci: da8xx: creation of gpio platform device Philip Avinash
2013-05-30 18:14   ` Linus Walleij
2013-05-22  7:10 ` [PATCH 05/11] ARM: davinci: creation of gpio platform device for dm platforms Philip Avinash
2013-05-30 18:15   ` Linus Walleij
2013-05-22  7:10 ` [PATCH 06/11] ARM: davinci: da8xx: gpio device creation Philip Avinash
2013-05-30 18:16   ` Linus Walleij
2013-05-22  7:10 ` [PATCH 07/11] ARM: davinci: create davinci gpio device for dm platforms Philip Avinash
2013-05-30 18:16   ` Linus Walleij
2013-05-22  7:10 ` [PATCH 08/11] ARM: davinci: start using gpiolib support Philip Avinash
2013-05-30 18:19   ` Linus Walleij
2013-05-22  7:10 ` [PATCH 09/11] gpio: davinci: DT changes for driver Philip Avinash
2013-05-30 18:25   ` Linus Walleij
2013-06-10 11:45     ` Philip, Avinash
2013-05-22  7:10 ` [PATCH 10/11] ARM: davinci: da850: add GPIO DT entries Philip Avinash
2013-05-22  7:10 ` [PATCH 11/11] ARM: davinci: da850 evm: add GPIO DT data Philip Avinash
2013-05-30 18:26   ` Linus Walleij
2013-05-30 18:04 ` [PATCH 00/11] Convert GPIO Davinci to platform driver Linus Walleij
2013-06-07  8:10 ` Sekhar Nori
2013-06-10  9:02   ` Philip, Avinash
2013-06-11  4:39     ` Sekhar Nori
2013-06-11  6:49       ` Philip, Avinash
2013-06-11 11:40         ` Sekhar Nori

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=51B98301.9090404@ti.com \
    --to=nsekhar@ti.com \
    --cc=avinashphilip@ti.com \
    --cc=davinci-linux-open-source@linux.davincidsp.com \
    --cc=grant.likely@secretlab.ca \
    --cc=khilman@deeprootsystems.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@arm.linux.org.uk \
    /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