summaryrefslogtreecommitdiffstats
path: root/drivers
Commit message (Collapse)AuthorAgeFilesLines
* mci imx-esdhc: increase write timeoutSascha Hauer2012-09-291-1/+1
| | | | | | | | | | The timeout for wating for the bus to be idle is too short when the card does internal garbage collection. This was triggered with filling an SD card under Linux with /dev/urandom, then doing a saveenv under barebox afterwards. Linux has timeouts here up to 300ms. Use a second to be safe. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* mtd mtdraw: fix fixing partial page readSascha Hauer2012-09-201-1/+1
| | | | | | | | | | | | | | | toread is unitialized. We have to use count instead. | commit 992c291e9561381cf86d4a7fc9271c2b60fea0c1 | Author: Sascha Hauer <s.hauer@pengutronix.de> | Date: Sat Sep 15 16:54:47 2012 +0200 | | mtd mtdraw: Fix partial page read | | When reading parts of a page we have to limit the maximum bytes copied | to the remaining bytes of a page. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* net/tap: use xzalloc to allocate dataJean-Christophe PLAGNIOL-VILLARD2012-09-201-2/+2
| | | | | | | this will ensure the data are set to 0 (list as example) Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* mtd mtdraw: Fix partial page readSascha Hauer2012-09-161-1/+2
| | | | | | | | When reading parts of a page we have to limit the maximum bytes copied to the remaining bytes of a page. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Acked-by: Robert Jarzmik <robert.jarzmik@free.fr>
* miidev: fix 1G wrong detectionEric Bénard2012-09-141-24/+9
| | | | | | | | | | since 99e72c8bbdbdc690025a5868d831f1fe79ad56fc on an i.MX51 based board, I get : "phy0: Link is up - 1000/Full". It seems miidev tries to probe the PHY to early and gets 0x3ffff which leads to the wrong capabilities setting. Signed-off-by: Eric Bénard <eric@eukrea.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* tap: fix missing parent setting on eth_deviceJean-Christophe PLAGNIOL-VILLARD2012-09-121-0/+1
| | | | | Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* smsc911x: Check platformdata pointerJan Weitzel2012-09-101-2/+2
| | | | | | | | If pdata is NULL smc911x_probe will crash. Checking the zero initialized priv->shift results in default configuration if pdata is not set. Signed-off-by: Jan Weitzel <j.weitzel@phytec.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* smc911x: fix typo pn check if the device is ready before using itJean-Christophe PLAGNIOL-VILLARD2012-09-101-1/+1
| | | | | | | the check need to be inverted Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* mtd/mtdraw: fix format specifier for ssize_tJan Luebbe2012-09-071-1/+1
| | | | | Signed-off-by: Jan Luebbe <jlu@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* mtd: use correct format specifierJan Luebbe2012-09-071-2/+2
| | | | | | | | | For the size_t type the format specifier %zu or %zx must be used. See Documentation/printk-formats.txt in the kernel for details. Signed-off-by: Jan Luebbe <jlu@pengutronix.de> Acked-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/usb'Sascha Hauer2012-09-051-1/+2
|\
| * usb: use ep-specific pwrgood delaySteffen Trumtrar2012-08-311-1/+2
| | | | | | | | | | | | | | | | | | | | | | In usb_hub_configure the hub is asked for its descriptor and among other things its bPwrOn2PwrGood time. In the actual hub_power_on function this information was not used and a hardcoded value was used instead. For some hubs this delay is to short. So, use the delay the hub wants. Signed-off-by: Steffen Trumtrar <s.trumtrar@pengutronix.de> Signed-off-by: Michael Grzeschik <m.grzeschik@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Merge branch 'for-next/smc911x'Sascha Hauer2012-09-053-396/+541
|\ \
| * | smc911x: check if the device is ready before using itJean-Christophe PLAGNIOL-VILLARD2012-09-031-1/+11
| | | | | | | | | | | | | | | | | | | | | | | | poll the READY bit in PMT_CTRL. Any other access to the device is forbidden while this bit isn't set. Try for 100ms Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | smc911x: update chip detectionJean-Christophe PLAGNIOL-VILLARD2012-09-032-39/+34
| | | | | | | | | | | | | | | | | | | | | Use linux kernel chip detection from 3.5 Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | smc911x: improve detection handleJean-Christophe PLAGNIOL-VILLARD2012-09-032-1/+22
| | | | | | | | | | | | | | | | | | | | | detect if the bus is swapped and report a 32bit drivers is used on a 16bit bus Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | smc911x: add support to pass the shift via platform dataJean-Christophe PLAGNIOL-VILLARD2012-09-033-42/+85
| | | | | | | | | | | | | | | | | | | | | switch ipe337: to it at the same time to do not brake it Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | smc911x: add 16bit bus width supportJean-Christophe PLAGNIOL-VILLARD2012-09-031-5/+29
| | | | | | | | | | | | | | | Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | smc911x: introduce read/write opsJean-Christophe PLAGNIOL-VILLARD2012-09-031-38/+63
| | | | | | | | | | | | | | | | | | | | | | | | This will allow to replace them depending on the platform data. So we can specify shift and reg io witdh (16bit/32bit) Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | smc911x: move register define to smc911x.hJean-Christophe PLAGNIOL-VILLARD2012-09-032-327/+354
| | | | | | | | | | | | | | | | | | | | | this make the driver more readable Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | Merge branch 'for-next/ppc'Sascha Hauer2012-09-054-0/+838
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: arch/ppc/boards/freescale-p2020rdb/p2020rdb.c arch/ppc/configs/p2020rdb_defconfig arch/ppc/mach-mpc85xx/include/mach/immap_85xx.h
| * | | net: GIANFAR driverRenaud Barbier2012-08-104-0/+838
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This update adds the GIANFAR driver along with the configuration and build files. Signed-off-by: Renaud Barbier <renaud.barbier@ge.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | | Merge branch 'for-next/pbl'Sascha Hauer2012-09-052-0/+11
|\ \ \ \
| * | | | ARM boards: Make boards pbl safeSascha Hauer2012-08-121-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With pbl support enabled most boards need a pbl-y for their lowlevel stuff. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Acked-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
| * | | | ARM s3c boards: Do not hardcode image sizesSascha Hauer2012-08-121-0/+10
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The existing nand_boot functions all do the same, so move it to a common place. To be flexible enough for future boards the real image size is used instead of hardcoded 256k. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Acked-by: Juergen Beisert <jbe@pengutronix.de> Acked-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
* | | | Merge branch 'for-next/omap'Sascha Hauer2012-09-052-44/+153
|\ \ \ \
| * | | | mtd OMAP NAND: implement buswidth autodetection supportSascha Hauer2012-08-031-13/+31
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | | mtd nand: implement buswidth detectionSascha Hauer2012-08-031-4/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This introduces a new NAND_BUSWIDTH_AUTO flag which can be used to automatically detect the nand buswidth. The id is always read in 8bit mode. An additional callback is needed to switch the nand controller into 16bit mode. This currently depends on a safe read_byte (always) and read_buf (for onfi-only flashes) callback. It has been tested on OMAP, but is not something that generally works. For this reason the existence of the set_buswidth callback is used to determine whether we are able to do autodetection or not. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | | mtd OMAP NAND: Use prefetch engineSascha Hauer2012-08-031-0/+100
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use the prefetch engine to improve NAND performance. The howto is derived from the Kernel. Unlike the kernel we do not make the access mode configurable. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | | mtd OMAP NAND: Fix dev_ready handlingSascha Hauer2012-08-021-28/+7
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - dev_ready is supposed to return whether the device is ready or not, not to poll until the device is ready. - dev_ready should return true for ready and false for not ready - waitpin polarity is not needed (at least the kernel does not have it) - wait_mon_mask must be 32bit. The code was unused since no board specified a wait pin, so no breakage included. This also removes the now unused timeout variable from platformdata. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | | Merge branch 'for-next/mtd'Sascha Hauer2012-09-054-11/+40
|\ \ \ \
| * | | | mtd: add private data to mtddev-hookAlexander Aring2012-09-034-6/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The mtdoob and mtdraw device don't clean up correctly. Added a private data element to hold allocated memory. Fix remove of mtdoob and mtdraw device. Signed-off-by: Alexander Aring <alex.aring@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | | mtd: fix compiler warningsAlexander Aring2012-09-032-5/+5
| | |/ / | |/| | | | | | | | | | | | | | | | | | | | | | Fix some compiler warnings. Signed-off-by: Alexander Aring <alex.aring@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | | Merge branch 'for-next/misc'Sascha Hauer2012-09-051-1/+1
|\ \ \ \
| * | | | net: miidev: really wait for auto negotiationWolfram Sang2012-09-031-1/+1
| | |/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | miidev_wait_aneg() polled the wrong bit, so link detection did fail on boards where the PHY had to come out of a powerdown mode. Signed-off-by: Wolfram Sang <w.sang@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | | Merge branch 'for-next/mc13xxx'Sascha Hauer2012-09-051-5/+26
|\ \ \ \
| * | | | mc13xxx: Fixed memory leakAlexander Shiyan2012-09-041-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A string allocated by asprintf is not freed, so change it to a sprintf with the preallocated buffer. Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | | mc13xxx: Hide private struct mc13xxx from other unitsAlexander Shiyan2012-09-041-0/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Board support units must use only the provided functions. Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | | mc13xxx: Added mc13xxx_revision() function.Alexander Shiyan2012-08-101-0/+6
| |/ / / | | | | | | | | | | | | | | | | Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | | Merge branch 'for-next/jtag'Sascha Hauer2012-09-055-0/+416
|\ \ \ \
| * | | | Add JTAG bitbang driverWjatscheslaw Stoljarski2012-08-135-0/+416
| |/ / / | | | | | | | | | | | | | | | | Signed-off-by: Wjatscheslaw Stoljarski <wjatscheslaw.stoljarski@kiwigrid.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | | Merge branch 'for-next/imx'Sascha Hauer2012-09-052-2/+2
|\ \ \ \
| * | | | i.MX35: add cspi1 supportEric Bénard2012-08-292-2/+2
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | tested with a m25p128 flash both in nand boot & spi boot. Signed-off-by: Eric Bénard <eric@eukrea.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | | Merge branch 'for-next/i2c'Sascha Hauer2012-09-052-128/+200
|\ \ \ \
| * | | | i2c: adapt the i2c-imx driver to mpc85xx machinesRenaud Barbier2012-09-042-12/+83
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A function to calculate the frequency divider and digital filter sampling rate for the 85xx processors is added to the i2c-imx driver. Hence, this driver is usable on IMX and 85xx machines. Signed-off-by: Renaud Barbier <renaud.barbier@ge.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | | | IMX driver: replace imx -> fslRenaud Barbier2012-09-041-117/+118
| | |/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The IMX i2c driver is to be used by SOCs on both the ARM and PPC architetures. Use a more neutral name for the structure, function names and #define. The driver name is now "i2c-fsl". Signed-off-by: Renaud Barbier <renaud.barbier@ge.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | | gpio: add driver for stmpe io-expanderSteffen Trumtrar2012-09-053-0/+173
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Steffen Trumtrar <s.trumtrar@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | | mfd: add stmpe-i2c driverSteffen Trumtrar2012-09-053-0/+158
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The stmpe mfds can be connected via i2c and spi. This driver provides the basic infrastructure for the i2c kind. It can be added as a normal i2c-device in the board code. To enable functions a platform_data struct has to be provided, that describes what parts of the chip are to be used. Signed-off-by: Steffen Trumtrar <s.trumtrar@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | | ARM i.MX: switch to gpiolib supportSascha Hauer2012-09-041-0/+1
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Steffen Trumtrar <s.trumtrar@pengutronix.de>
* | | | add gpiolib supportSascha Hauer2012-09-044-0/+138
|/ / / | | | | | | | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Steffen Trumtrar <s.trumtrar@pengutronix.de>