public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Wolfgang Grandegger <wg@grandegger.com>
To: Abhilash K V <abhilash.kv@ti.com>
Cc: linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, tony@atomide.com,
	linux@arm.linux.org.uk, Sriramakrishnan <srk@ti.com>
Subject: Re: [PATCH] can : AM3517EVM : add platform specific init
Date: Fri, 11 Mar 2011 17:57:59 +0100	[thread overview]
Message-ID: <4D7A5497.4070801@grandegger.com> (raw)
In-Reply-To: <1299775153-16766-1-git-send-email-abhilash.kv@ti.com>

On 03/10/2011 05:39 PM, Abhilash K V wrote:
> CAN module on AM3517 requires programming of IO expander
> as part of init sequence. Added transceiver_switch
> callback to handle this.
> 
> Signed-off-by: Sriramakrishnan <srk@ti.com>
> Reviewed-by:  Vaibhav Hiremath <hvaibhav@ti.com>
> Signed-off-by: Abhilash K V <abhilash.kv@ti.com>
> ---
>  arch/arm/mach-omap2/board-am3517evm.c |   18 ++++++++++++++++++
>  1 files changed, 18 insertions(+), 0 deletions(-)
> 
> diff --git a/arch/arm/mach-omap2/board-am3517evm.c b/arch/arm/mach-omap2/board-am3517evm.c
> index 2e4aad2..782d72d 100644
> --- a/arch/arm/mach-omap2/board-am3517evm.c
> +++ b/arch/arm/mach-omap2/board-am3517evm.c
> @@ -734,6 +734,23 @@ static struct omap_board_mux board_mux[] __initdata = {
>  };
>  #endif
>  
> +/*
> + * HECC information
> + */
> +
> +#define CAN_STB         214
> +static void hecc_phy_control(int on)
> +{
> +        int r;
> +
> +        r = gpio_request(CAN_STB, "can_stb");
> +        if (r) {
> +                printk(KERN_ERR "failed to get can_stb \n");
> +                return;
> +        }
> +
> +        gpio_direction_output(CAN_STB, (on==1)?0:1);
> +}

This function is called ony *any* ifconfig up and down request. I would
expect gpio_request() will return -EBUSY when it's called more than once.

Wolfgang.


      parent reply	other threads:[~2011-03-11 16:55 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-10 16:39 [PATCH] can : AM3517EVM : add platform specific init Abhilash K V
2011-03-11 12:19 ` Sergei Shtylyov
2011-03-11 16:57 ` Wolfgang Grandegger [this message]

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=4D7A5497.4070801@grandegger.com \
    --to=wg@grandegger.com \
    --cc=abhilash.kv@ti.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=linux@arm.linux.org.uk \
    --cc=srk@ti.com \
    --cc=tony@atomide.com \
    /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