- 30 9月, 2020 40 次提交
-
-
由 Pratyush Yadav 提交于
When more nodes are added for a uclass the index might go into two or more digits. This means that there are less spaces printed because they are used up by the extra digits. Update the regular expression to allow variable-length spacing between the class name and and index. This was discovered when adding a simple_bus node in test.dts made test_bind_unbind_with_uclass() fail because the index went up to 10. Signed-off-by: NPratyush Yadav <p.yadav@ti.com>
-
由 Jean-Jacques Hiblot 提交于
A regmap field is an abstraction available in Linux. It provides to access bitfields in a regmap without having to worry about shifts and masks. Signed-off-by: NJean-Jacques Hiblot <jjhiblot@ti.com> Reviewed-by: NSimon Glass <sjg@chromium.org> Signed-off-by: NPratyush Yadav <p.yadav@ti.com>
-
由 Pratyush Yadav 提交于
Some devices need to calculate the regmap base address at runtime. This makes it impossible to use device tree to get the regmap base. Instead, allow devices to specify it in the regmap config. This will create a regmap with a single range that corresponds to the start and size given by the driver. Signed-off-by: NPratyush Yadav <p.yadav@ti.com> Reviewed-by: NSimon Glass <sjg@chromium.org>
-
由 Pratyush Yadav 提交于
Right now, the base of a regmap can only be obtained from the device tree. This makes it impossible for devices which calculate the base at runtime to use a regmap. An example of such a device is the Cadence Sierra PHY. Allow creating a regmap with one range whose start and size can be specified by the driver based on calculations at runtime. Signed-off-by: NPratyush Yadav <p.yadav@ti.com> Reviewed-by: NSimon Glass <sjg@chromium.org>
-
由 Pratyush Yadav 提交于
Drivers can configure it to adjust the final read/write location. Signed-off-by: NPratyush Yadav <p.yadav@ti.com> Reviewed-by: NSimon Glass <sjg@chromium.org>
-
由 Pratyush Yadav 提交于
Right now, regmap_read() and regmap_write() read/write a 32-bit value only. To write other lengths, regmap_raw_read() and regmap_raw_write() need to be used. This means that any driver ported from Linux that relies on regmap_{read,write}() to know the size already has to be updated at each callsite. This makes the port harder to maintain. So, allow specifying the read/write width to make it easier to port the drivers, since now the only change needed is when initializing the regmap. Signed-off-by: NPratyush Yadav <p.yadav@ti.com> Reviewed-by: NSimon Glass <sjg@chromium.org>
-
由 Pratyush Yadav 提交于
Some fields will be introduced in the regmap structure that should be set to 0 by default. So, once we allocate a regmap, make sure it is zeroed out to avoid unexpected defaults for those values. Signed-off-by: NPratyush Yadav <p.yadav@ti.com> Reviewed-by: NSimon Glass <sjg@chromium.org>
-
由 Jean-Jacques Hiblot 提交于
Most of new linux drivers are using managed-API to allocate resources. To ease porting drivers from linux to U-Boot, introduce devm_regmap_init() as a managed API to get a regmap from the device tree. Signed-off-by: NJean-Jacques Hiblot <jjhiblot@ti.com> Reviewed-by: NSimon Glass <sjg@chromium.org> Signed-off-by: NPratyush Yadav <p.yadav@ti.com>
-
由 Jean-Jacques Hiblot 提交于
Add a test to verify that GPIOs can be acquired/released using the managed API. Also check that the GPIOs are released when the consumer device is removed. Signed-off-by: NJean-Jacques Hiblot <jjhiblot@ti.com> Reviewed-by: NSimon Glass <sjg@chromium.org> Signed-off-by: NPratyush Yadav <p.yadav@ti.com>
-
由 Jean-Jacques Hiblot 提交于
Add managed functions to get a gpio from the devce-tree, based on a property name (minus the '-gpios' suffix) and optionally an index. When the device is unbound, the GPIO is automatically released and the data structure is freed. Signed-off-by: NJean-Jacques Hiblot <jjhiblot@ti.com> Reviewed-by: NSimon Glass <sjg@chromium.org> Signed-off-by: NPratyush Yadav <p.yadav@ti.com>
-
由 Jean-Jacques Hiblot 提交于
The tests are basically the same as for the regular API. Except that the reset are initialized using the managed API, and no freed manually. Signed-off-by: NJean-Jacques Hiblot <jjhiblot@ti.com> Reviewed-by: NSimon Glass <sjg@chromium.org> Signed-off-by: NPratyush Yadav <p.yadav@ti.com>
-
由 Jean-Jacques Hiblot 提交于
Add managed functions to get a reset_ctl from the device-tree, based on a name or an index. Also add a managed functions to get a reset_ctl_bulk (array of reset_ctl) from the device-tree. When the device is unbound, the reset controllers are automatically released and the data structure is freed. Signed-off-by: NJean-Jacques Hiblot <jjhiblot@ti.com> Reviewed-by: NSimon Glass <sjg@chromium.org> Signed-off-by: NPratyush Yadav <p.yadav@ti.com>
-
https://gitlab.denx.de/u-boot/custodians/u-boot-riscv由 Tom Rini 提交于
- Disable CMD_IRQ for RISC-V. - Update sipeed/maix doc - Obtain reg of SiFive RAM via dev_read_addr_index() instead of regmap API. - Cleans up RISC-V timer drivers and converts them to DM. - Correctly handle IPIs already pending upon prior stage bootloader (on the K210)
-
由 Tom Rini 提交于
- Improve our dev_xxx(..) wrappers to be generally used and available rather than discarded at link/compile time.
-
由 Sean Anderson 提交于
This adorns messages generated by dev_xxx with the device and driver names. It also redirects dev_xxx to log when it is available. The names of these functions very roughly take inspiration from Linux, but there is no deeper correlation. Both struct udevice and struct device are supported when logging, though logging with struct device is no better than using log_xxx. The latter is supported because of the large amount of existing code which logs with struct device. Signed-off-by: NSean Anderson <seanga2@gmail.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
This substitutes literal log levels with their symbolic constants. Signed-off-by: NSean Anderson <seanga2@gmail.com> Reviewed-by: NSimon Glass <sjg@chromium.org> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
There is no member `dev` in dw_mipi_dsi, but there is one in mipi_dsi_host, so use that. Signed-off-by: NSean Anderson <seanga2@gmail.com> Reviewed-by: NPatrick Delaunay <patrick.delaunay@st.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
This driver does not use DM, so we need to use a struct device instead of a struct udevice. Not ideal, but it'll have to do for now. Signed-off-by: NSean Anderson <seanga2@gmail.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
This can conflict with asm/io.h on some archs, and it isn't needed to build dwc3-generic.c Signed-off-by: NSean Anderson <seanga2@gmail.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
This driver does not use DM, so use log_xxx instead. Signed-off-by: NSean Anderson <seanga2@gmail.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
This logs with the device from struct dwc3. Some files also need to include dm.h so fields in udevice can be accessed. Signed-off-by: NSean Anderson <seanga2@gmail.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
This adds a dev argument to some functions so dev_xxx always has a device to log with. In one instance we must use use a different log function when we are compiled without DM_USB. Signed-off-by: NSean Anderson <seanga2@gmail.com> Reviewed-by: NPatrice Chotard <patrice.chotard@st.com> Reviewed-by: NPatrick Delaunay <patrick.delaunay@st.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
ep0.c also need to include dm.h so dev_xxx can access udevice fields. Signed-off-by: NSean Anderson <seanga2@gmail.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
The rst variable doesn't exist. Signed-off-by: NSean Anderson <seanga2@gmail.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
Use `bus` instead of `dev`. Signed-off-by: NSean Anderson <seanga2@gmail.com> Reviewed-by: NMichal Simek <michal.simek@xilinx.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
Use `bus` and not `dev`. Signed-off-by: NSean Anderson <seanga2@gmail.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
Remove the indirection. Signed-off-by: NSean Anderson <seanga2@gmail.com> Reviewed-by: NSimon Glass <sjg@chromium.org> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
Pass a device to functions which log with one. Signed-off-by: NSean Anderson <seanga2@gmail.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
Usually we can get a device from the current core, but some dev_dbg calls have been converted to debug, since we are called on a cluster. Signed-off-by: NSean Anderson <seanga2@gmail.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
This function is never used anywhere, and it also tries to log with a nonexistant device. Signed-off-by: NSean Anderson <seanga2@gmail.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
Use the phy's device. Signed-off-by: NSean Anderson <seanga2@gmail.com> Reviewed-by: NPatrice Chotard <patrice.chotard@st.com> Reviewed-by: NPatrick Delaunay <patrick.delaunay@st.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
`phy` doesn't exist; we need to use `x` instead. Signed-off-by: NSean Anderson <seanga2@gmail.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
This uses phy's device Signed-off-by: NSean Anderson <seanga2@gmail.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
Get the device from phy, or pass the phy in. Signed-off-by: NSean Anderson <seanga2@gmail.com> Reviewed-by: NKever Yang <kever.yang@rock-chips.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
No need for indirection here. Signed-off-by: NSean Anderson <seanga2@gmail.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
Without DM_ETH, cpsw_priv.dev is an eth_device. Just use its name instead. Signed-off-by: NSean Anderson <seanga2@gmail.com> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
Pass a udevice into a few functions so `dev` is defined. Signed-off-by: NSean Anderson <seanga2@gmail.com> Reviewed-by: NSimon Glass <sjg@chromium.org> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
There's no dev to log with, so pass the device along with the priv data. Signed-off-by: NSean Anderson <seanga2@gmail.com> Reviewed-by: NSimon Glass <sjg@chromium.org> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
No drivers in U-Boot use these functions. Signed-off-by: NSean Anderson <seanga2@gmail.com> Reviewed-by: NSimon Glass <sjg@chromium.org> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-
由 Sean Anderson 提交于
netdev_xxx evaluates to printf in U-Boot, so there is no extra info printed. mvpp2 one of only two drivers which use these functions in U-Boot. Convert these functions to dev_xxx where possible (and to log_xxx where not). Signed-off-by: NSean Anderson <seanga2@gmail.com> Reviewed-by: NSimon Glass <sjg@chromium.org> Tested-by: NPatrick Delaunay <patrick.delaunay@st.com>
-