9
0
Fork 0
Commit Graph

43 Commits

Author SHA1 Message Date
Sascha Hauer 8c349b5526 ARM: AT91: move iomux definitions to iomux.h
mach/gpio.h is for the gpio API, so move unrelated stuff
away.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2013-08-16 15:58:33 +02:00
Sascha Hauer 1081856788 ARM: include <gpio.h> instead of <mach/gpio.h>
The gpio api should be used from <gpio.h>

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2013-08-16 15:58:33 +02:00
Josh Cartwright 28acd8331d macb: rename platform data
The macb/gem core is used by the Zynq SoC.  In preparation of sharing
the macb driver between at91 and Zynq, rename the platform data to
'struct macb_platform_data', and move the definition to a common
location.

Signed-off-by: Josh Cartwright <joshc@eso.teric.us>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2013-04-03 17:21:51 +02:00
Jean-Christophe PLAGNIOL-VILLARD 3b4fdb58c0 at91sam9: drop AT91_BASE_SYS for sdram controller
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2013-02-05 10:26:49 +01:00
Jean-Christophe PLAGNIOL-VILLARD f7e3126619 macb: allow to pass the phy interface
as we will add later the GMAC IP verion support (GEM)

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2013-01-29 11:44:49 +01:00
Jean-Christophe PLAGNIOL-VILLARD b01ded9a97 at91: usb: allow to specicfy inverted vbus
add missing vbus to all SoC

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2013-01-23 08:57:22 +01:00
Jean-Christophe PLAGNIOL-VILLARD 8ad5725465 at91: use gpio_is_valid to check gpio
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-12-22 16:40:33 +01:00
Jean-Christophe PLAGNIOL-VILLARD c811546712 macb/ether: split flags for drivers and phylib
as in the kernel use is_rmii
flags for pinctrl
phy_flags for phylib flags

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-11-19 10:19:08 +01:00
Jean-Christophe PLAGNIOL-VILLARD 71a67b33d1 at91sam9260/sam9g20: add i2c support
use i2c-gpio as the hw ip is broken

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-11-15 20:20:29 +01:00
Jean-Christophe PLAGNIOL-VILLARD 46a11f99ff at91: sam9260/sam9g20/sam9261/sam9g10/sam9263 add autodetect sdram size
if 0 is passed to at91_add_device_sdram autodetect the sdram size

The amount of available ram is determined by the SDRAMC_CR register.

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-08-03 15:51:02 +02:00
Sascha Hauer 5f03074ea9 resource: store 'end' instead of 'size' in struct resource
Storing the size instead of the resource end in struct resource was
a mistake. 'size' ranges from 0 to UINT[32|64]_MAX + 1 which obviously
leads to problems. 'end' on the other hand will never exceed
UINT[32|64]_MAX. Also this way we can express a iomem region covering
the whole address space.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-07-01 08:18:53 +02:00
Jean-Christophe PLAGNIOL-VILLARD d72083674a at91: switch uart registration to inline
this allow to save between 100 to 300 bytes

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-05-29 10:16:35 +02:00
Sascha Hauer ce38019845 Merge branch 'next'
Conflicts:
	common/hush.c

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-05-03 20:10:13 +02:00
Jean-Christophe PLAGNIOL-VILLARD f44268517f at91: at91_register_uart use number instead of IDs
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2012-04-24 18:27:30 +08:00
Sascha Hauer abe4560c8a Use DEVICE_ID_DYNAMIC where applicable
We now have DEVICE_ID_DYNAMIC for dynamic allocation of device ids,
Use it where applicable.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-04-16 09:43:02 +02:00
Jean-Christophe PLAGNIOL-VILLARD 28bdc0e3da ARM: at91: allow to pass the interface id to at91_add_device_eth
On the sam9x5 series we now support 1 or 2 macb.

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-04-02 10:31:23 +02:00
Jean-Christophe PLAGNIOL-VILLARD 77a8d36b90 at91: at91_register_uart return device
this will allow to set the active parameter from C

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2012-02-16 18:17:34 +08:00
Sascha Hauer 192d6fe9be Merge branch 'pu/debug' into next 2012-01-27 09:31:13 +01:00
Jean-Christophe PLAGNIOL-VILLARD 3874b16997 atmel/mci: fix slot_b support
in commit commit f60f6c58e
atmel_mci: check for device id we use to address the right slot

the driver use the dev_id to detect the slot which is wrong on 9263 as we have
2 devices with 2 slots

use slot_b paramter to specify the slot as done in linux

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Cc: Michael Grzeschik <m.grzeschik@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-01-16 09:33:41 +01:00
Jean-Christophe PLAGNIOL-VILLARD 78af988e41 at91: add default spi chipselect ressources
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-01-06 09:42:30 +01:00
Jean-Christophe PLAGNIOL-VILLARD d816bb4cc0 at91: add spi device ressources
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-01-06 09:42:30 +01:00
Jean-Christophe PLAGNIOL-VILLARD 543bd82619 at91: 9260 and 9g20 add support of join SRAM Memory Mapping
on 9269 and 9g20 the sram are mirrored at then of the bank so we can join them

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-01-06 09:42:30 +01:00
Jean-Christophe PLAGNIOL-VILLARD 4c8fa9f064 at91: add sram memory devices
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2012-01-02 12:08:24 +01:00
Jean-Christophe PLAGNIOL-VILLARD c100eacc25 at91: add at91_udc resource
this device controller is present on rm9200/9260/9g20/9261/9g10/9263

the 9g45 use an other IP

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-12-23 18:15:29 +01:00
Michael Grzeschik 1a46f8b6d4 at91sam9260_devices: add flag to change ETX{2,3} pincfg on add_device_eth
Signed-off-by: Michael Grzeschik <m.grzeschik@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-12-07 09:39:12 +01:00
Michael Grzeschik 0cbda4e76a at91sam9260_devices: properly set slot id
Signed-off-by: Michael Grzeschik <m.grzeschik@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-12-07 09:39:12 +01:00
Hubert Feurstein 32aeb0245d at91: add missing clkdev changes
This fixes the following compile errors
  arch/arm/mach-at91/at91sam9g45.c:185:3: error: 'ohci_clk' undeclared here (not in a function)
  arch/arm/mach-at91/at91sam9g45.c:186:3: error: 'tcb1_clk' undeclared here (not in a function)
  arch/arm/mach-at91/at91sam9g45_devices.c: In function 'at91_add_device_mci':
  arch/arm/mach-at91/at91sam9g45_devices.c:258:2: warning: implicit declaration of function 'at91_clock_associate'
    [...]
  arch/arm/mach-at91/built-in.o: In function `at91_add_device_mci':
  sam9_smc.c:(.text.at91_add_device_mci+0x1d0): undefined reference to `at91_clock_associate'

  arch/arm/mach-at91/at91sam9260_devices.c: In function 'at91_add_device_mci':
  arch/arm/mach-at91/at91sam9260_devices.c:251:2: warning: implicit declaration of function 'at91_clock_associate'

which were introduced in commit:
  "at91: swtich to clkdev" (ae19fe26cc)

Signed-off-by: Hubert Feurstein <h.feurstein@gmail.com>
Cc: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-09-20 21:36:23 +02:00
Jean-Christophe PLAGNIOL-VILLARD 413c5a9f07 at91: add ohci support
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-09-20 21:12:46 +02:00
Jean-Christophe PLAGNIOL-VILLARD afdfa915ce at91: nand switch ecc base to resource
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-09-20 21:12:46 +02:00
Jean-Christophe PLAGNIOL-VILLARD b9605d8a96 at91: swtich to clkdev
this will also fix the clock support as we now switch to allocated generic
device

as we can need to associate the clock and the device but the driver is probe
before the association

we also change the atmel serial name to "atmel_usart" to simplify sharing with
linux

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-08-10 14:53:06 +02:00
Jean-Christophe PLAGNIOL-VILLARD 95067e23ac arm: introduce arm_add_mem_device to register dram device
this will automaticaly register the device to armlinux_add_dram

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2011-08-01 21:49:33 +08:00
Jean-Christophe PLAGNIOL-VILLARD 6f3aa82310 at91: switch to add_generic_device
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2011-07-22 18:30:51 +08:00
Jean-Christophe PLAGNIOL-VILLARD eb18395e07 at91: add missing IORESOURCE_MEM flags to resources
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-07-20 08:25:43 +02:00
Sascha Hauer f928efa818 add a add_mem_device function
Add a helper function for boards to register their memory
devices. This makes the board code smaller and also helps
getting rid of map_base and struct memory_platform_data.

And switch all of the memory to it

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2011-07-18 20:32:45 +08:00
Jean-Christophe PLAGNIOL-VILLARD 88618eb5f1 mem: replace DEVFS_RDWR by IORESOURCE_MEM_WRITEABLE
we keep struct memory_platform_data for now on we will switch off the memories
resources to struct resource

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2011-07-18 20:31:51 +08:00
Jean-Christophe PLAGNIOL-VILLARD 643b2f620f at91: switch to all resource declaration to "struct resource"
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2011-07-18 07:57:50 +08:00
Hubert Feurstein 6cf02124b1 mci: add Atmel AT91 MCI driver
The driver supports push and pull transfers.
Tested on at91sam9m10 SoC.

Signed-off-by: Hubert Feurstein <h.feurstein@gmail.com>
2011-06-16 17:54:12 +02:00
Jean-Christophe PLAGNIOL-VILLARD ba685b2a8c at91sam9260/at91sam9263: use the same id as in the kernel for the uart devices
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2010-11-11 20:43:17 +08:00
Jean-Christophe PLAGNIOL-VILLARD e85c6bb0a7 driver: use id as -1 for auto assigned id
before if you specify id = 0 the next available id will be taken
otherwise fail if already registered now as in linux we use -1

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-09-20 08:58:52 +02:00
Jean-Christophe PLAGNIOL-VILLARD 873910050e at91: implement clock framework
this implementation is based on linux one (v2.6.35-rc5-76-gd0c6f62)
it will calculate all the clock dynamically instead of statictly
this will use also the new clock framework

it will also print the clock status after the console init

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-08-06 19:09:00 +02:00
Jean-Christophe PLAGNIOL-VILLARD f6a579da9c [ARM] Move include/asm-arm/arch-* to arch/arm/*/include/mach
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2009-10-22 14:21:25 +02:00
Jean-Christophe PLAGNIOL-VILLARD a08615b2da at91sam9: switch to the same api as the kernel
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2009-10-20 15:02:39 +02:00
Jean-Christophe PLAGNIOL-VILLARD 7ac3805353 at91: add cpu devices common api
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2009-10-20 15:02:37 +02:00