| ede709c0 | 10-Jul-2013 |
Marek Vasut <marex@denx.de> |
usb: mv_udc: Implement better qTD item accessor
The code for retrieving qTD item for particular endpoint is hard to understand, moreover it's duplicated all over the driver. Move the code into singl
usb: mv_udc: Implement better qTD item accessor
The code for retrieving qTD item for particular endpoint is hard to understand, moreover it's duplicated all over the driver. Move the code into single nice and documented function.
Signed-off-by: Marek Vasut <marex@denx.de> Cc: Fabio Estevam <fabio.estevam@freescale.com> Cc: Lei Wen <leiwen@marvell.com> Cc: Otavio Salvador <otavio@ossystems.com.br> Cc: Stefano Babic <sbabic@denx.de>
show more ...
|
| 8a095a68 | 10-Jul-2013 |
Marek Vasut <marex@denx.de> |
usb: mv_udc: Improve allocation of qTD items
Allocate the qTD items all at once instead of allocating them separately. Moreover, make sure each qTD is properly aligned to 32-bytes boundary and that
usb: mv_udc: Improve allocation of qTD items
Allocate the qTD items all at once instead of allocating them separately. Moreover, make sure each qTD is properly aligned to 32-bytes boundary and that cache can be safely flushed over each qTD touple.
Signed-off-by: Marek Vasut <marex@denx.de> Cc: Fabio Estevam <fabio.estevam@freescale.com> Cc: Lei Wen <leiwen@marvell.com> Cc: Otavio Salvador <otavio@ossystems.com.br> Cc: Stefano Babic <sbabic@denx.de>
show more ...
|
| b5cd45bf | 10-Jul-2013 |
Marek Vasut <marex@denx.de> |
usb: mv_udc: Implement better QH accessor
The code for retrieving QH for particular endpoint is hard to understand, moreover it's duplicated all over the driver. Move the code into single nice and d
usb: mv_udc: Implement better QH accessor
The code for retrieving QH for particular endpoint is hard to understand, moreover it's duplicated all over the driver. Move the code into single nice and documented function.
Signed-off-by: Marek Vasut <marex@denx.de> Cc: Fabio Estevam <fabio.estevam@freescale.com> Cc: Lei Wen <leiwen@marvell.com> Cc: Otavio Salvador <otavio@ossystems.com.br> Cc: Stefano Babic <sbabic@denx.de>
show more ...
|
| 5804b885 | 10-Jul-2013 |
Marek Vasut <marex@denx.de> |
usb: mv_udc: Add cacheline length check
Check the length of system cacheline at compile-time and fail if the system uses too long cachelines.
Signed-off-by: Marek Vasut <marex@denx.de> Cc: Fabio Es
usb: mv_udc: Add cacheline length check
Check the length of system cacheline at compile-time and fail if the system uses too long cachelines.
Signed-off-by: Marek Vasut <marex@denx.de> Cc: Fabio Estevam <fabio.estevam@freescale.com> Cc: Lei Wen <leiwen@marvell.com> Cc: Otavio Salvador <otavio@ossystems.com.br> Cc: Stefano Babic <sbabic@denx.de>
show more ...
|
| ab65da14 | 10-Jul-2013 |
Marek Vasut <marex@denx.de> |
usb: mv_udc: Properly align the endpoint QH and qTD list
The endpoint QH list has to be aligned to 10-bit boundary. We also have to make sure the list is aligned on a cacheline boundary. Make sure i
usb: mv_udc: Properly align the endpoint QH and qTD list
The endpoint QH list has to be aligned to 10-bit boundary. We also have to make sure the list is aligned on a cacheline boundary. Make sure it is. Furthermore, check if the memory allocation for the QH list didn't fail. Moveover, improve the comment about the QH list structure.
Finally, the qTD item list has to be aligned only to 5-bit boundary, not 10-bit as it is now, fix this as well.
Signed-off-by: Marek Vasut <marex@denx.de> Cc: Fabio Estevam <fabio.estevam@freescale.com> Cc: Lei Wen <leiwen@marvell.com> Cc: Otavio Salvador <otavio@ossystems.com.br> Cc: Stefano Babic <sbabic@denx.de>
show more ...
|
| ab52df19 | 10-Jul-2013 |
Marek Vasut <marex@denx.de> |
usb: mv_udc: Move QH and qTD into mv_drv
Both the endpoint queue head and the endpoint item list is a controller specific thing. Move them both into controller private data.
Signed-off-by: Marek Va
usb: mv_udc: Move QH and qTD into mv_drv
Both the endpoint queue head and the endpoint item list is a controller specific thing. Move them both into controller private data.
Signed-off-by: Marek Vasut <marex@denx.de> Cc: Fabio Estevam <fabio.estevam@freescale.com> Cc: Lei Wen <leiwen@marvell.com> Cc: Otavio Salvador <otavio@ossystems.com.br> Cc: Stefano Babic <sbabic@denx.de>
show more ...
|
| fe48f058 | 10-Jul-2013 |
Marek Vasut <marex@denx.de> |
usb: mv_udc: Init mv_drv.gadget.ops statically
There is no need to init this field at runtime, so init it statically.
Signed-off-by: Marek Vasut <marex@denx.de> Cc: Fabio Estevam <fabio.estevam@fre
usb: mv_udc: Init mv_drv.gadget.ops statically
There is no need to init this field at runtime, so init it statically.
Signed-off-by: Marek Vasut <marex@denx.de> Cc: Fabio Estevam <fabio.estevam@freescale.com> Cc: Lei Wen <leiwen@marvell.com> Cc: Otavio Salvador <otavio@ossystems.com.br> Cc: Stefano Babic <sbabic@denx.de>
show more ...
|
| f6463177 | 10-Jul-2013 |
Marek Vasut <marex@denx.de> |
usb: mv_udc: Remove QH_MAXNUM macro
The QH_MAXNUM is used in absolutelly incorrect manner and is not even needed. Remove it and correctly replace it's occurance with 2 * NUM_ENDPOINTS .
Signed-off-
usb: mv_udc: Remove QH_MAXNUM macro
The QH_MAXNUM is used in absolutelly incorrect manner and is not even needed. Remove it and correctly replace it's occurance with 2 * NUM_ENDPOINTS .
Signed-off-by: Marek Vasut <marex@denx.de> Cc: Fabio Estevam <fabio.estevam@freescale.com> Cc: Lei Wen <leiwen@marvell.com> Cc: Otavio Salvador <otavio@ossystems.com.br> Cc: Stefano Babic <sbabic@denx.de>
show more ...
|
| d7663038 | 10-Jul-2013 |
Marek Vasut <marex@denx.de> |
usb: mv_udc: Clean up the initial variable check
Clean up the code that checks the validity of a USB gadget driver in usb_gadget_register_driver(). Moreover, limit the speed of the driver to either
usb: mv_udc: Clean up the initial variable check
Clean up the code that checks the validity of a USB gadget driver in usb_gadget_register_driver(). Moreover, limit the speed of the driver to either FULL or HIGH, this is more precise and once we have xHCI support, also more correct.
Signed-off-by: Marek Vasut <marex@denx.de> Cc: Fabio Estevam <fabio.estevam@freescale.com> Cc: Lei Wen <leiwen@marvell.com> Cc: Otavio Salvador <otavio@ossystems.com.br> Cc: Stefano Babic <sbabic@denx.de>
show more ...
|
| be7ed253 | 10-Jul-2013 |
Marek Vasut <marex@denx.de> |
usb: mv_udc: Make use of struct ehci_ctrl
The usb_lowlevel_init() call already fills and passes back struct ehci_ctrl , which readily contains correctly determined address of the port register block
usb: mv_udc: Make use of struct ehci_ctrl
The usb_lowlevel_init() call already fills and passes back struct ehci_ctrl , which readily contains correctly determined address of the port register block address computed from values from controller configuration registers. Leverage this and make use of this value as this makes the code mode universal, but also gets us rid of the CONFIG_USB_REG_BASE configuration option.
Moreover, this patch cleans up the usb_gadget_register_driver() call a little by correcting the error handling. Note the usb_lowlevel_init() and mvudc_probe() are now called in reversed order, but this has no impact on the code.
Signed-off-by: Marek Vasut <marex@denx.de> Cc: Fabio Estevam <fabio.estevam@freescale.com> Cc: Lei Wen <leiwen@marvell.com> Cc: Otavio Salvador <otavio@ossystems.com.br> Cc: Stefano Babic <sbabic@denx.de>
show more ...
|
| 2ea4b448 | 10-Jul-2013 |
Marek Vasut <marex@denx.de> |
usb: mv_udc: Clean up the EP initialization
Move the constant values that are programmed into mv_ep.ep into separate static const structure so they can be memcpy()'d when the initialization happens.
usb: mv_udc: Clean up the EP initialization
Move the constant values that are programmed into mv_ep.ep into separate static const structure so they can be memcpy()'d when the initialization happens.
Moveover, we only every init NUM_ENDPOINTS, not 2 * NUM_ENDPOINTS, so fix this bug as well.
Signed-off-by: Marek Vasut <marex@denx.de> Cc: Fabio Estevam <fabio.estevam@freescale.com> Cc: Lei Wen <leiwen@marvell.com> Cc: Otavio Salvador <otavio@ossystems.com.br> Cc: Stefano Babic <sbabic@denx.de>
show more ...
|
| 532d846f | 10-Jul-2013 |
Marek Vasut <marex@denx.de> |
usb: mv_udc: Move endpoint array into driver data
The endpoints are operated on a per-controller basis, move the endpoint array into controller's private data. Also shuffle the struct mv_ep structur
usb: mv_udc: Move endpoint array into driver data
The endpoints are operated on a per-controller basis, move the endpoint array into controller's private data. Also shuffle the struct mv_ep structure definition just above the definition of the struct mv_drv so they're well grouped together.
Signed-off-by: Marek Vasut <marex@denx.de> Cc: Fabio Estevam <fabio.estevam@freescale.com> Cc: Lei Wen <leiwen@marvell.com> Cc: Otavio Salvador <otavio@ossystems.com.br> Cc: Stefano Babic <sbabic@denx.de>
show more ...
|
| ecc8edbf | 26-Jun-2013 |
Mike Dunn <mikedunn@newsguy.com> |
usb: pxa27x_udc: fix compiler warnings
Newer gcc versions warn about unused variables. This patch corrects a few of those warnings that popped up in a build for the palmtreo680 board.
Signed-off-b
usb: pxa27x_udc: fix compiler warnings
Newer gcc versions warn about unused variables. This patch corrects a few of those warnings that popped up in a build for the palmtreo680 board.
Signed-off-by: Mike Dunn <mikedunn@newsguy.com>
show more ...
|
| e059a400 | 26-Jun-2013 |
Lukasz Majewski <l.majewski@samsung.com> |
dfu:function: Fix number of allocated DFU function pointers
This subtle change fix problem with too small amount of allocated memory to store DFU function pointers.
One needs to allocate extra spac
dfu:function: Fix number of allocated DFU function pointers
This subtle change fix problem with too small amount of allocated memory to store DFU function pointers.
One needs to allocate extra space for sentinel NULL pointer in this array of function pointers.
With the previous code, the NULL value overwrites malloc internal data and afterwards free(f_dfu->function) crashes.
Signed-off-by: Lukasz Majewski <l.majewski@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Cc: Marek Vasut <marex@denx.de>
show more ...
|
| c5398cc9 | 04-Jun-2013 |
Heiko Schocher <hs@denx.de> |
usb, g_dnl: make possibility to fixup the device_desc board specific
add a weak dummy function g_dnl_fixup to add the possibility to update the device_desc board specific. Used on the upcoming sieme
usb, g_dnl: make possibility to fixup the device_desc board specific
add a weak dummy function g_dnl_fixup to add the possibility to update the device_desc board specific. Used on the upcoming siemens board support, where idVendor and idProduct is stored in an eeprom.
Signed-off-by: Heiko Schocher <hs@denx.de> Cc: Marek Vasut <marek.vasut@gmail.com> Cc: Lukasz Majewski <l.majewski@samsung.com> Cc: Kyungmin Park <kyungmin.park@samsung.com> Reviewed-by: Lukasz Majewski <l.majewski@samsung.com>
show more ...
|
| ad5f9778 | 25-Jun-2013 |
Heiko Schocher <hs@denx.de> |
usb, dfu gadget: switch to dfu mode in dfu_bind
- set in to_dfu_mode() f_dfu->dfu_state = DFU_STATE_dfuIDLE as after every to_dfu_mode call this is done, so move this into to_dfu_mode - switch i
usb, dfu gadget: switch to dfu mode in dfu_bind
- set in to_dfu_mode() f_dfu->dfu_state = DFU_STATE_dfuIDLE as after every to_dfu_mode call this is done, so move this into to_dfu_mode - switch in dfu_bind() into dfu mode: This fixes wrong "dfu-util -l" output, when calling "dfu-util -l" after a board reset, without doing a download before. See also discussion here:
http://lists.denx.de/pipermail/u-boot/2013-June/157272.html
Signed-off-by: Heiko Schocher <hs@denx.de> Cc: Lukasz Majewski <l.majewski@samsung.com> Cc: Pantelis Antoniou <panto@antoniou-consulting.com> Cc: Tom Rini <trini@ti.com> Cc: Kyungmin Park <kyungmin.park@samsung.com> Cc: Marek Vasut <marex@denx.de> Cc: Wolfgang Denk <wd@denx.de> Cc: Samuel Egli <samuel.egli@siemens.com> Acked-by: Lukasz Majewski <l.majewski@samsung.com> Tested-by: Lukasz Majewski <l.majewski@samsung.com>
show more ...
|
| 12595e99 | 10-Apr-2013 |
Piotr Wilczek <p.wilczek@samsung.com> |
usb:composite: use memcpy to avoid unaligned access
This patch memcpy is used instead of an assignment to avoid unaligned access execption on some ARM platforms.
Signed-off-by: Piotr Wilczek <p.wil
usb:composite: use memcpy to avoid unaligned access
This patch memcpy is used instead of an assignment to avoid unaligned access execption on some ARM platforms.
Signed-off-by: Piotr Wilczek <p.wilczek@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> CC: Lukasz Majewski <l.majewski@samsung.com> Tested-by: Heiko Schocher <hs@denx.de> Acked-by: Heiko Schocher <hs@denx.de>
show more ...
|
| c67b0e42 | 04-Jun-2013 |
Heiko Schocher <hs@denx.de> |
usb, composite: after unregister gadget driver set composite to NULL
Without this, second usb_composite_register() call fails always with -EINVAL.
Signed-off-by: Heiko Schocher <hs@denx.de> Cc: Luk
usb, composite: after unregister gadget driver set composite to NULL
Without this, second usb_composite_register() call fails always with -EINVAL.
Signed-off-by: Heiko Schocher <hs@denx.de> Cc: Lukasz Majewski <l.majewski@samsung.com> Cc: Kyungmin Park <kyungmin.park@samsung.com> Cc: Marek Vasut <marex@denx.de>
show more ...
|