Skip to content

Commit

Permalink
USB: atmel_usba_udc: change way of specifying bias function
Browse files Browse the repository at this point in the history
The toggle_bias() function was specified differently for avr32 and at91
architectures. Now, new at91 have the same behavior as avr32.
Consequently, we change to a particular chip function definition: only for
at91sam9rl.

Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Acked-by: Haavard Skinnemoen <haavard.skinnemoen@atmel.com>
Acked-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Nicolas Ferre authored and Greg Kroah-Hartman committed Jun 16, 2009
1 parent 23a54e5 commit e60c65d
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions drivers/usb/gadget/atmel_usba_udc.c
Original file line number Diff line number Diff line change
Expand Up @@ -326,13 +326,7 @@ static int vbus_is_present(struct usba_udc *udc)
return 1;
}

#if defined(CONFIG_AVR32)

static void toggle_bias(int is_on)
{
}

#elif defined(CONFIG_ARCH_AT91)
#if defined(CONFIG_ARCH_AT91SAM9RL)

#include <mach/at91_pmc.h>

Expand All @@ -346,7 +340,13 @@ static void toggle_bias(int is_on)
at91_sys_write(AT91_CKGR_UCKR, uckr & ~(AT91_PMC_BIASEN));
}

#endif /* CONFIG_ARCH_AT91 */
#else

static void toggle_bias(int is_on)
{
}

#endif /* CONFIG_ARCH_AT91SAM9RL */

static void next_fifo_transaction(struct usba_ep *ep, struct usba_request *req)
{
Expand Down

0 comments on commit e60c65d

Please sign in to comment.