Commit Graph

17404 Commits

Author SHA1 Message Date
Stefan Roese
5d1c883329 ppc4xx: Canyonlands/Glacier: Squeeze NAND image a bit to fit again
This patch removes some superfluous SDRAM init calls to fit the
NAND_SPL image into 4k again.

Signed-off-by: Stefan Roese <sr@denx.de>
2012-09-03 11:29:07 +02:00
Joe Hershberger
de15a06aad cfi: Make the flash erase and write operations abortable
Check for ctrlc() in operations that take time and loop over the flash
addresses.

In netconsole, tstc() is expensive.  Only check once in a while to not
slow down the operation significantly.

Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
Signed-off-by: Stefan Roese <sr@denx.de>
2012-09-03 11:24:27 +02:00
Joe Hershberger
6822a647b9 cfi: Check for blank before erase
Added an optional check in the CFI driver to evaluate if the sector is
already blank before issuing an erase command.  Improves erase time by
over a factor of 10 if already blank.

Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
Signed-off-by: Stefan Roese <sr@denx.de>
2012-09-03 11:24:27 +02:00
Anatolij Gustschin
e5ab702a6c powerpc: re-add bi_ip_addr to bd_t struct
Since commit 50a47d0523
(net: punt bd->bi_ip_addr) booting old 2.4.x ppc kernels
is broken due to changed offsets of the fields in struct bd_t.
Offsets of the fields after removed bi_ip_addr are wrong,
causing wrong bus clocks and console baudrate configurations
and various other issues. Re-add the bi_ip_addr field to preserve
backward compatibility with older ppc kernels. Setting bi_ip_addr
in board.c is not really needed, grepping in the 2.4 linux tree
shows that bi_ip_addr is not accessed there. Adding bi_ip_addr
to struct bd_t for other arches isn't needed it seems. bd_t is
not used by other arches in the 2.4 linux tree.

Signed-off-by: Anatolij Gustschin <agust@denx.de>
Acked-by: Wolfgang Denk <wd@denx.de>
2012-09-02 22:55:59 +02:00
Joe Hershberger
a005f19eff hush: Don't parse the contents of a dereferenced var
When a variable which contains a user-supplied value is dereferenced
(e.g. to be echo'ed), make sure that the value is not further parsed
by hush.

Set the hush local variable "HUSH_NO_EVAL=1" to enable this behavior.

Without this patch, a sequence like this occurs:

	Panda # env set my_user_string Bob\'s favorite device
	Panda # print my_user_string
	my_user_string=Bob's favorite device
	Panda # echo $my_user_string
	syntax error hush.c:3007

With this patch, it looks like this:

	Panda # HUSH_NO_EVAL=1
	Panda # env set my_user_string Bob\'s favorite device
	Panda # print my_user_string
	my_user_string=Bob's favorite device
	Panda # echo $my_user_string
	Bob's favorite device

Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2012-09-02 20:31:21 +02:00
Joe Hershberger
641b0d374e hush: Add default value substitution support
Use standard sh syntax:
${VAR:-default}
	Use default value: if VAR is set and non-null, expands to $VAR.
	Otherwise, expands to default.
${VAR:=default}
	Set default value: if VAR is set and non-null, expands to $VAR.
	Otherwise, sets hush VAR to default and expands to default.
${VAR:+default}
	If VAR is set and non-null, expands to the empty string.
	Otherwise, expands to default.

Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
2012-09-02 20:30:24 +02:00
Karl O. Pinc
923c46f97a README: Cleanup description of supported partitions.
README: Cleanup description of supported partitions.

Signed-off-by: Karl O. Pinc <kop@meme.com>
2012-09-02 19:41:57 +02:00
Tom Rini
c3567d808d README.SPL: Move the 'Estimating stack usage' from omap3 to here
The instructions are generic, so move to the generic doc.

Signed-off-by: Tom Rini <trini@ti.com>
2012-09-02 19:39:46 +02:00
Tom Rini
f8e754d51c README.SPL: Add a small Debugging section
Signed-off-by: Tom Rini <trini@ti.com>
2012-09-02 19:39:25 +02:00
Benoît Thébaudeau
a1ea8e5109 README: Update ver env var description
Commit 155cb01 replaced the read-only property of the ver env var
with an auto-restoring behavior. Update the README file accordingly.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Cc: Wolfgang Denk <wd@denx.de>
2012-09-02 18:56:41 +02:00
Tomáš Hlaváček
bfae89abf1 dm: Add twserial device document
Signed-off-by: Tomas Hlavacek<tmshlvck@gmail.com>
2012-09-02 18:00:02 +02:00
Tomas Hlavacek
0d9e59948a dm: RTC subsystem analysis added.
Signed-off-by: Tomas Hlavacek <tmshlvck@gmail.com>
2012-09-02 18:00:02 +02:00
Viktor Krivak
cbcc33e951 dm: Add pcmcia design document
Signed-off-by: Viktor Krivak <viktor.krivak@gmail.com>
2012-09-02 18:00:01 +02:00
Pavel Herrmann
a09c649972 dm: add PCI design document
Signed-off-by: Pavel Herrmann <morpheus.ibis@gmail.com>
2012-09-02 18:00:01 +02:00
Tomas Hlavacek
f07563a7a5 dm: Driver model analysis document for Watchdog subsystem has been added.
Signed-off-by: Tomas Hlavacek <tmshlvck@gmail.com>
2012-09-02 18:00:01 +02:00
Tomas Hlavacek
5df9b142a1 dm: Hwmon UDM subsystem analysis added.
Signed-off-by: Tomas Hlavacek <tmshlvck@gmail.com>
2012-09-02 18:00:01 +02:00
Viktor Krivak
6246fdb055 dm: Add POWER API transition document
Signed-off-by: Viktor Krivak <viktor.krivak@gmail.com>
2012-09-02 18:00:01 +02:00
Pavel Herrmann
0463574014 dm: Add block device document
Signed-off-by: Pavel Herrmann <morpheus.ibis@gmail.com>
2012-09-02 18:00:00 +02:00
Viktor Krivak
707a5e2226 dm: Add SPI API transition document
Signed-off-by: Viktor Krivak <viktor.krivak@gmail.com>
2012-09-02 18:00:00 +02:00
Marek Vasut
b59d2802d2 dm: Add networking subsystem analysis
Signed-off-by: Marek Vasut <marex@denx.de>
2012-09-02 18:00:00 +02:00
Marek Vasut
2568182674 dm: Add MMC subsystem analysis
Signed-off-by: Marek Vasut <marek.vasut@gmail.com>
2012-09-02 18:00:00 +02:00
Viktor Křivák
68bce384f4 dm: Add GPIO API transition document
Signed-off-by: Viktor Křivák <viktor.krivak@gmail.com>
2012-09-02 18:00:00 +02:00
Pavel Herrmann
3f4669334d dm: Add Driver cores design document
Signed-off-by: Pavel Herrmann <morpheus.ibis@gmail.com>
2012-09-02 17:55:56 +02:00
Marek Vasut
15c6935b0c dm: Initial import of design documents
This patch contains UDM-design.txt, which is document containing
general description of the driver model. The remaining files contains
descriptions of conversion process of particular subsystems.

Signed-off-by: Marek Vasut <marek.vasut@gmail.com>
2012-09-02 17:55:53 +02:00
Stephan Linz
c20dbf64a9 input: key_matrix: fix header inclusion
On Microblaze with device tree support enabled we run into
the error below.

I'm not sure, but I think that all source code should include
at least the common.h and just this fix the problem on
Microblaz architecture.

The error is:

In file included from key_matrix.c:29:
include/malloc.h:364: error: conflicting types for 'memset'
include/linux/string.h:71: error: previous declaration of 'memset' was here
include/malloc.h:365: error: conflicting types for 'memcpy'
include/linux/string.h:74: error: previous declaration of 'memcpy' was here

Signed-off-by: Stephan Linz <linz@li-pro.net>
CC: Bernie Thompson <bhthompson@chromium.org>
CC: Simon Glass <sjg@chromium.org>
CC: Tom Warren <twarren@nvidia.com>
CC: Michal Simek <monstr@monstr.eu>
Acked-by: Simon Glass <sjg@chromium.org>
Acked-by: Michal Simek <monstr@monstr.eu>
2012-09-02 17:44:20 +02:00
Mike Frysinger
8a156fb6e4 fix out of tree building with kallsyms
The call to SYSTEM_MAP assumes that the u-boot output is in $PWD when
it really should be in $(obj).  This fixes building out of tree.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2012-09-02 17:41:38 +02:00
Stephen Warren
3801a15f67 env_nand: align NAND buffers
This allows cache flush/invalidate operations to succeed on the buffers.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Acked-by: Simon Glass <sjg@chromium.org>
Acked-by: Scott Wood <scottwood@freescale.com>
2012-09-02 17:40:19 +02:00
Jagannadha Sutradharudu Teki
cee84e8257 image/FIT: Add ramdisk load, entry address and OS tag inclusion
This patch adds support to include Load, Entry address and OS tag
of ramdisk on to FIT image through mkimage tool.

Signed-off-by: Jagannadha Sutradharudu Teki <402jagan@gmail.com>
2012-09-02 17:39:15 +02:00
Benoît Thébaudeau
df930e9b3c rtc: pcf8563: Make century compatible with Linux
This driver uses the century bit of this RTC in the opposite way Linux does.
From Linux's rtc-pcf8563.c:
	/*
	 * The meaning of MO_C bit varies by the chip type.
	 * From PCF8563 datasheet: this bit is toggled when the years
	 * register overflows from 99 to 00
	 *   0 indicates the century is 20xx
	 *   1 indicates the century is 19xx
	 * From RTC8564 datasheet: this bit indicates change of
	 * century. When the year digit data overflows from 99 to 00,
	 * this bit is set. By presetting it to 0 while still in the
	 * 20th century, it will be set in year 2000, ...
	 * There seems no reliable way to know how the system use this
	 * bit.  So let's do it heuristically, assuming we are live in
	 * 1970...2069.
	 */

As U-Boot's PCF8563 driver does not say it is supposed to support the RTC8564,
make this driver compatible with Linux's by giving the opposite meaning to the
century bit.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Cc: Wolfgang Denk <wd@denx.de>
2012-09-02 17:31:00 +02:00
Benoît Thébaudeau
0880e5bb0c FAT: Simplify get_contents
One call to get_cluster can be factorized with another, so avoid
duplicating code.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Cc: Wolfgang Denk <wd@denx.de>
2012-09-02 17:22:43 +02:00
Benoît Thébaudeau
cc63b25efb FAT: get_cluster: Add buffer bouncing
Add a buffer bouncing mechanism to get_cluster.  This can be useful
for misaligned applicative buffers passed through get_contents.
This is required for the following patches in the case of data
aligned differently relatively to buffers and clusters.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Cc: Wolfgang Denk <wd@denx.de>
2012-09-02 17:22:10 +02:00
Benoît Thébaudeau
cd1b042c5c FAT: Fix redundant sector read
With the previous code, the remaining prefetched sectors were read
again after each sector.  With this patch, each sector is read only
once, thus making the prefetch useful.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Cc: Wolfgang Denk <wd@denx.de>
2012-09-02 17:16:08 +02:00
Benoît Thébaudeau
88503ad3bb FAT: cosmetic: Remove useless assignment
fatlength is not used after this assignment, so it is useless and can
be removed.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Cc: Wolfgang Denk <wd@denx.de>
2012-09-02 17:15:16 +02:00
Benoît Thébaudeau
8006dd2e57 FAT: get_fatent: Fix FAT boundary check
startblock must be taken into account in order not to read past the
end of the FAT.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Cc: Wolfgang Denk <wd@denx.de>
2012-09-02 17:14:30 +02:00
Benoît Thébaudeau
9795e07b04 FAT: cosmetic: Remove extra spaces
Remove spaces before opening parentheses in function calls.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Cc: Wolfgang Denk <wd@denx.de>
2012-09-02 17:13:18 +02:00
Joakim Tjernlund
83f83d1935 ppc: Create a stack frame for wait_ticks()
wait_ticks() calls get_ticks() without building a back chain which
makes gdb unhappy when doing back trace. This can also cause
improper memory accesses.

Signed-off-by: Joakim Tjernlund <Joakim.Tjernlund@transmode.se>
2012-09-02 17:10:21 +02:00
Benoît Thébaudeau
64a08a9ffc part_mac: dcache: allocate cacheline-aligned buffers
This patch forces the correct alignment for DMA operations of buffers used by
part_mac.c.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Cc: Wolfgang Denk <wd@denx.de>
2012-09-02 17:08:31 +02:00
Kaspter Ju
67cbbf25c5 mmc: Remove unused item flags in struct mmc_cmd
Signed-off-by: Kaspter Ju <nigh0st3018@gmail.com>
2012-09-02 16:56:17 +02:00
Charles Manning
74f45b739b u-boot yaffs2: Fix compilation warnings
Also remove yaffs_hweight and use the hweight in u-boot.

Signed-off-by: Charles Manning <cdhmanning@gmail.com>
2012-09-02 16:47:50 +02:00
Wolfgang Denk
7cdcaef0b2 Merge branch 'master' of git://git.denx.de/u-boot-usb
* 'master' of git://git.denx.de/u-boot-usb:
  MUSB driver: Timeout is never detected as the while loop does not end
  usb: fix ulpi_set_vbus prototype
  pxa25x: Add UDC registers definitions
  USB: Fix strict aliasing in ohci-hcd
  usb: Optimize USB storage read/write
  ehci: Optimize qTD allocations
  usb_stor_BBB_transport: Do not delay when not required
  usb_storage: Remove EHCI constraints
  usb_storage: Restore non-EHCI support
  ehci-hcd: Boost transfer speed
  ehci: cosmetic: Define used constants
  ehci: Fail for multi-transaction interrupt transfers
  arm:trats: Enable g_dnl composite USB gadget with embedded DFU function on TRATS
  arm:trats: Support for USB UDC driver at TRATS board.
  dfu:cmd: Support for DFU u-boot command
  dfu: MMC specific routines for DFU operation
  dfu: DFU backend implementation
  dfu:usb: DFU USB function (f_dfu) support for g_dnl composite gadget
  dfu:usb: Support for g_dnl composite download gadget.
  ehci: cosmetic: Define the number of qt_buffers

Signed-off-by: Wolfgang Denk <wd@denx.de>
2012-09-02 16:38:48 +02:00
Otavio Salvador
43de0244c1 patman: Do not Cc addresses included in To list
In case an address is listed in the To list, those will be skipped on
Cc list or user might end with a duplicated message.

This fixes the case when a tag points to same address used as series
destination thus avoiding duplicated sending.

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2012-09-02 16:27:07 +02:00
Otavio Salvador
d5f81d8acd patman: Allow for changelog use in first version of a series
When a patchset had a RFC series, a v1 might have a changelog of
changes done since the RFC. The patch changes the range checked for
changelog and allow it to start for version 1.

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Acked-by: Simon Glass <sjg@chromium.org>
2012-09-02 16:25:33 +02:00
Ilya Yanok
c7379149ff patman: don't mess with signoffs
Currently patman assumes that there should be only one Signoff line
and this is obviously incorrect: we often have to work with patches
containing other people signoffs. Moreover, it's really desirable
to preserve the comments between signoffs.

So until some sophisticated signoff processing will be developed I
suggest just don't mess with signoffs at all and treat them like
plain text lines. The only drawback I've found so far is the case
where you have a patch with someones else signoff but not yours and
also have to patman tags under signoff line. In this case you will
get extra empty line between signoffs.

Signed-off-by: Ilya Yanok <ilya.yanok@cogentembedded.com>
2012-09-02 16:24:51 +02:00
Ilya Yanok
73fe07a79a patman: don't mess with changelog
Don't try to sort and uniq changelog entries as this breaks
multiline entries. It will be better to add some real multi-line
support but for now just preserve the entries as is.

Signed-off-by: Ilya Yanok <ilya.yanok@cogentembedded.com>
2012-09-02 16:24:07 +02:00
Ilya Yanok
a8840cb2f0 patman: don't pick changes while processing patches
We already got all changes from git log output and the comment
to the ProcessLine function clearly states that 'patch' mode
is not for scanning tags.

Signed-off-by: Ilya Yanok <ilya.yanok@cogentembedded.com>
2012-09-02 16:23:33 +02:00
Ilya Yanok
05e5b73506 patman: fix end of changes detection
Changes may end in '---' line or Signoff line (generated by
git format-patch) in case of Series-changes: lines being
the last ones in commit message. So detect it properly.

Signed-off-by: Ilya Yanok <ilya.yanok@cogentembedded.com>
2012-09-02 16:22:49 +02:00
Andrew Sharp
69fd2d3b05 pci: add CONFIG_PCI_ENUM_ONLY for platforms that don't need PCI setup done
Introduce CONFIG_PCI_ENUM_ONLY variable for platforms that just want a
quick enumberation of the PCI devices, but don't need any setup work done.
This is very beneficial on platforms that have u-boot loaded by another
boot loader which does a more sophisticated job of setup of PCI devices
than u-boot.  That way, u-boot can just read what's there and get on
with life.  This is what SeaBIOS does.

Signed-off-by: Andrew Sharp <andywyse6@gmail.com>
2012-09-02 14:19:05 +02:00
Andrew Sharp
98c397a6ed pci: update pci_ids.h with a few new entries
Add some recent entries to pci_ids.h for Intel and AMD/ATI devices that
are somewhat relevant to u-boot.

Signed-off-by: Andrew Sharp <andywyse6@gmail.com>
2012-09-02 14:18:52 +02:00
Andrew Sharp
03992ac2c9 pci: minor cleanup of CONFIG_PCI_PNP usage
Refactor the common PCI code just a tiny bit surrounding the PCI_PNP
(pciauto) stuff.  Makes the code a tiny bit easier to read, and also
makes it more obvious that almost no platform needs to setup or use the
pci_config_table stuff.

Signed-off-by: Andrew Sharp <andywyse6@gmail.com>
2012-09-02 14:18:19 +02:00
Andrew Sharp
cb2bf931dc pci: clean up some whitespace and formatting
I tried to clean up the white space and formatting offenses and
inconsistencies in the generic PCI code that obviously has been around for
some time.  Emphasis on large increases in readability and maintainability
and consistency.  I omitted the platform/processor specific files in
the drivers/pci directory because I wanted to leave those file to those
that care more about them.

Signed-off-by: Andrew Sharp <andywyse6@gmail.com>
2012-09-02 14:17:52 +02:00