| 1d5827a1 | 25-Mar-2015 |
Simon Glass <sjg@chromium.org> |
dm: usb: Fix type problems in usb_stor_get_info()
This function assumes that unsigned long is 32-bits wide, but it is not on 64-bit machines. Use the correct type, and add a few debug() lines also.
dm: usb: Fix type problems in usb_stor_get_info()
This function assumes that unsigned long is 32-bits wide, but it is not on 64-bit machines. Use the correct type, and add a few debug() lines also.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Marek Vasut <marex@denx.de>
show more ...
|
| 2e17c87e | 25-Mar-2015 |
Simon Glass <sjg@chromium.org> |
dm: usb: Move USB storage definitions to usb_defs.h
These are better off in a header file so they can be used by other code (e.g. the sandbox USB storage emulator).
Signed-off-by: Simon Glass <sjg@
dm: usb: Move USB storage definitions to usb_defs.h
These are better off in a header file so they can be used by other code (e.g. the sandbox USB storage emulator).
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Marek Vasut <marex@denx.de>
show more ...
|
| 054fe48e | 25-Mar-2015 |
Simon Glass <sjg@chromium.org> |
dm: usb: Add driver model support for hubs
Adjust the existing hub code to support driver model, and add a USB driver for hubs.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Marek Vasu
dm: usb: Add driver model support for hubs
Adjust the existing hub code to support driver model, and add a USB driver for hubs.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Marek Vasut <marex@denx.de>
show more ...
|
| 361ad6af | 25-Mar-2015 |
Simon Glass <sjg@chromium.org> |
dm: usb: Split hub detection into its own function
Split out the hub detection logic so it can be used by driver model. Also adjust the code to return errors correctly.
Signed-off-by: Simon Glass <
dm: usb: Split hub detection into its own function
Split out the hub detection logic so it can be used by driver model. Also adjust the code to return errors correctly.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Marek Vasut <marex@denx.de>
show more ...
|
| 95fbfe42 | 25-Mar-2015 |
Simon Glass <sjg@chromium.org> |
dm: usb: Convert core usb.c file to support driver model
Add the required #ifdefs and remove unwanted data structures so that the USB uclass will be able to use this file.
Signed-off-by: Simon Glas
dm: usb: Convert core usb.c file to support driver model
Add the required #ifdefs and remove unwanted data structures so that the USB uclass will be able to use this file.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Marek Vasut <marex@denx.de>
show more ...
|
| 0ed27905 | 25-Mar-2015 |
Simon Glass <sjg@chromium.org> |
dm: usb: Complete the splitting up of usb_new_device()
This function now calls usb_setup_device() to set up the device and usb_hub_probe() to check if it is a hub. The XHCI special case is now a par
dm: usb: Complete the splitting up of usb_new_device()
This function now calls usb_setup_device() to set up the device and usb_hub_probe() to check if it is a hub. The XHCI special case is now a parameter to usb_setup_device(). The latter will be used by the USB uclass when it is added, since it does not rely on any CONFIGs or legacy data structures.
Signed-off-by: Simon Glass <sjg@chromium.org> Bug-fixes for descriptor reading and usb_new_device() return value Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Marek Vasut <marex@denx.de> Tested-by: Tom Rini <trini@konsulko.com>
show more ...
|
| 91398f98 | 25-Mar-2015 |
Simon Glass <sjg@chromium.org> |
dm: usb: Split out more code from usb_new_device()
Move the code that sets up the device with a new address into its own function, usb_prepare_device().
Signed-off-by: Simon Glass <sjg@chromium.org
dm: usb: Split out more code from usb_new_device()
Move the code that sets up the device with a new address into its own function, usb_prepare_device().
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Marek Vasut <marex@denx.de>
show more ...
|
| 128fcac0 | 25-Mar-2015 |
Simon Glass <sjg@chromium.org> |
dm: usb: Move descriptor setup code into its own function
usb_new_device() is far too long and does far too much. As a first step, move the code that does initial setup and reads a descriptor into i
dm: usb: Move descriptor setup code into its own function
usb_new_device() is far too long and does far too much. As a first step, move the code that does initial setup and reads a descriptor into its own function called usb_setup_descriptor().
For XHCI the init order is different - we set up the device but don't actually read the descriptor until after we set an address. Support this option as a parameter to usb_setup_descriptor().
Avoid changing this torturous code more than necessary to make it easy to review.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Marek Vasut <marex@denx.de>
show more ...
|
| 862e75c0 | 25-Mar-2015 |
Simon Glass <sjg@chromium.org> |
dm: usb: Refactor port resets
Move the port reset code into its own function. Rename usb_hub_reset() to indicate that is is now a legacy function.
Signed-off-by: Simon Glass <sjg@chromium.org> Revi
dm: usb: Refactor port resets
Move the port reset code into its own function. Rename usb_hub_reset() to indicate that is is now a legacy function.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Marek Vasut <marex@denx.de>
show more ...
|
| 53d8aa0f | 25-Mar-2015 |
Simon Glass <sjg@chromium.org> |
dm: usb: Drop the legacy USB init sequence
This CONFIG is not used anywhere in U-Boot, so drop it.
Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Marek Vasut <marex@denx.de> |
| 6a1b206d | 25-Mar-2015 |
Simon Glass <sjg@chromium.org> |
dm: usb: Convert 'usb' command to support driver model
Adjust this command to work with the new driver model uclass. It needs to iterate through multiple independent controllers to find hubs, and wo
dm: usb: Convert 'usb' command to support driver model
Adjust this command to work with the new driver model uclass. It needs to iterate through multiple independent controllers to find hubs, and work through their children recursively in a different way. Otherwise the functionality is much the same.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Marek Vasut <marex@denx.de>
show more ...
|
| 79b58887 | 25-Mar-2015 |
Simon Glass <sjg@chromium.org> |
dm: usb: Adjust usb_alloc_new_device() to return an error
This function returns NULL on error at present. Adjust it so that we can return a real error, as is needed with driver model. Also improve t
dm: usb: Adjust usb_alloc_new_device() to return an error
This function returns NULL on error at present. Adjust it so that we can return a real error, as is needed with driver model. Also improve the error handling in its caller, usb_hub_port_connect_change(), and adjust the code order to prepare for driver model.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Marek Vasut <marex@denx.de>
show more ...
|
| cad4291c | 25-Mar-2015 |
Simon Glass <sjg@chromium.org> |
dm: usb: Adjust usb command to prepare for driver model
Use 'udev' instead of 'dev' in a few places, reserving 'dev' for driver model's struct udevice. Also adjust the code in a few minor ways to ma
dm: usb: Adjust usb command to prepare for driver model
Use 'udev' instead of 'dev' in a few places, reserving 'dev' for driver model's struct udevice. Also adjust the code in a few minor ways to make it easier to plumb in driver model.
Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Marek Vasut <marex@denx.de>
show more ...
|
| 7e0c77a2 | 26-Mar-2015 |
Simon Glass <sjg@chromium.org> |
cros_ec: Remove unused cros_ec_board_init() function
Now that driver model handles cros_ec init, we can drop this special code.
Signed-off-by: Simon Glass <sjg@chromium.org> |
| 60f37fc6 | 26-Mar-2015 |
Simon Glass <sjg@chromium.org> |
cros_ec: Drop unused CONFIG_DM_CROS_EC
Since all supported boards enable this option now, we can remove it along with the old code.
Signed-off-by: Simon Glass <sjg@chromium.org> |
| ba457562 | 26-Mar-2015 |
Simon Glass <sjg@chromium.org> |
dm: x86: spi: Convert ICH SPI driver to driver model
Convert this driver over to use driver model. Since all x86 platforms use it, move x86 to use driver model for SPI and SPI flash. Adjust all depe
dm: x86: spi: Convert ICH SPI driver to driver model
Convert this driver over to use driver model. Since all x86 platforms use it, move x86 to use driver model for SPI and SPI flash. Adjust all dependent code and remove the old x86 spi_init() function.
Note that this does not make full use of the new PCI uclass as yet. We still scan the bus looking for the device. It should move to finding its details in the device tree.
Signed-off-by: Simon Glass <sjg@chromium.org>
show more ...
|
| 05c3e68f | 22-Mar-2015 |
Joe Hershberger <joe.hershberger@ni.com> |
dm: eth: Add basic driver model support to Ethernet stack
First just add support for MAC drivers.
Signed-off-by: Joe Hershberger <joe.hershberger@ni.com> Reviewed-by: Simon Glass <sjg@chromium.org> |
| 85848f03 | 22-Mar-2015 |
Joe Hershberger <joe.hershberger@ni.com> |
cmd: net: Clean up return codes
The return codes in common/cmd_net.c had a number of inconsistencies. Update them to all use the enum from command.h
Signed-off-by: Joe Hershberger <joe.hershberger@
cmd: net: Clean up return codes
The return codes in common/cmd_net.c had a number of inconsistencies. Update them to all use the enum from command.h
Signed-off-by: Joe Hershberger <joe.hershberger@ni.com> Reviewed-by: Simon Glass <sjg@chromium.org>
show more ...
|
| d2eaec60 | 22-Mar-2015 |
Joe Hershberger <joe.hershberger@ni.com> |
net: Remove the bd* parameter from net stack functions
This value is not used by the network stack and is available in the global data, so stop passing it around. For the one legacy function that s
net: Remove the bd* parameter from net stack functions
This value is not used by the network stack and is available in the global data, so stop passing it around. For the one legacy function that still expects it (init op on old Ethernet drivers) pass in the global pointer version directly to avoid changing that interface.
Signed-off-by: Joe Hershberger <joe.hershberger@ni.com> Reported-by: Simon Glass <sjg@chromium.org> Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Simon Glass <sjg@chromium.org> (Trival fix to remove an unneeded variable declaration in 4xx_enet.c)
show more ...
|
| 0eb25b61 | 22-Mar-2015 |
Joe Hershberger <joe.hershberger@ni.com> |
common: Make sure arch-specific map_sysmem() is defined
In the case where the arch defines a custom map_sysmem(), make sure that including just mapmem.h is sufficient to have these functions as they
common: Make sure arch-specific map_sysmem() is defined
In the case where the arch defines a custom map_sysmem(), make sure that including just mapmem.h is sufficient to have these functions as they are when the arch does not override it.
Also split the non-arch specific functions out of common.h
Signed-off-by: Joe Hershberger <joe.hershberger@ni.com> Reviewed-by: Simon Glass <sjg@chromium.org>
show more ...
|
| 604c7d4a | 27-Mar-2015 |
Hannes Petermaier <hannes.petermaier@br-automation.com> |
common/lcd_console: introduce display/framebuffer rotation
Sometimes, for example if the display is mounted in portrait mode or even if it is mounted landscape but rotated by 180 degrees, we need to
common/lcd_console: introduce display/framebuffer rotation
Sometimes, for example if the display is mounted in portrait mode or even if it is mounted landscape but rotated by 180 degrees, we need to rotate our content of the display respectively the framebuffer, so that user can read the messages which are printed out.
For this we introduce the feature called "CONFIG_LCD_ROTATION", this may be defined in the board-configuration if needed. After this the lcd_console will be initialized with a given rotation from "vl_rot" out of "vidinfo_t" which is provided by the board specific code.
If CONFIG_LCD_ROTATION is not defined, the console will be initialized with 0 degrees rotation.
Signed-off-by: Hannes Petermaier <hannes.petermaier@br-automation.com> Signed-off-by: Hannes Petermaier <oe5hpm@oevsv.at> Acked-by: Nikita Kiryanov <nikita@compulab.co.il> [agust: fixed 'struct vidinfo' has no member named 'vl_rot' errors] Signed-off-by: Anatolij Gustschin <agust@denx.de>
show more ...
|
| 7471142c | 27-Mar-2015 |
Hannes Petermaier <hannes.petermaier@br-automation.com> |
common/lcd_console: move single static variables into common (static) structure
For coming implementation of lcd_console rotation, we will need some more variables for holding information about fram
common/lcd_console: move single static variables into common (static) structure
For coming implementation of lcd_console rotation, we will need some more variables for holding information about framebuffer size, rotation, ...
For better readability we catch all them into a common structure.
Signed-off-by: Hannes Petermaier <hannes.petermaier@br-automation.com> Signed-off-by: Hannes Petermaier <oe5hpm@oevsv.at> Acked-by: Nikita Kiryanov <nikita@compulab.co.il>
show more ...
|
| a202c5bd | 27-Mar-2015 |
Hannes Petermaier <hannes.petermaier@br-automation.com> |
common/lcd_console: ask only one-time for bg/fg-color per call
Don't call the lcd_getfgcolor and lcd_getbgcolor within the "draw-loop", this only wastes time.
Signed-off-by: Hannes Petermaier <hann
common/lcd_console: ask only one-time for bg/fg-color per call
Don't call the lcd_getfgcolor and lcd_getbgcolor within the "draw-loop", this only wastes time.
Signed-off-by: Hannes Petermaier <hannes.petermaier@br-automation.com> Signed-off-by: Hannes Petermaier <oe5hpm@oevsv.at> Acked-by: Nikita Kiryanov <nikita@compulab.co.il>
show more ...
|
| 97562c12 | 27-Mar-2015 |
Hannes Petermaier <hannes.petermaier@br-automation.com> |
common/lcd_console: cleanup lcd_drawchars/lcd_putc_xy
the capability of drawing some *str with count from lcd_drawchars is unnary. It is always called from lcd_putc_xy with one character of and coun
common/lcd_console: cleanup lcd_drawchars/lcd_putc_xy
the capability of drawing some *str with count from lcd_drawchars is unnary. It is always called from lcd_putc_xy with one character of and count = 1.
So we simply rename lcd_drawchars into lcd_putc_xy and remove the loops inside.
Signed-off-by: Hannes Petermaier <hannes.petermaier@br-automation.com> Signed-off-by: Hannes Petermaier <oe5hpm@oevsv.at> Acked-by: Nikita Kiryanov <nikita@compulab.co.il>
show more ...
|
| ff3e077b | 05-Mar-2015 |
Simon Glass <sjg@chromium.org> |
dm: pci: Add a uclass for PCI
Add a uclass for PCI controllers and a generic one for PCI devices. Adjust the 'pci' command and the existing PCI support to work with this new uclass. Keep most of the
dm: pci: Add a uclass for PCI
Add a uclass for PCI controllers and a generic one for PCI devices. Adjust the 'pci' command and the existing PCI support to work with this new uclass. Keep most of the compatibility code in a separate file so that it can be removed one day.
TODO: Add more header file comments to the new parts of pci.h
Signed-off-by: Simon Glass <sjg@chromium.org>
show more ...
|