- 22 9月, 2022 1 次提交
-
-
由 Arnaud Pouliquen 提交于
Define a platform driver to manage the remoteproc virtio device as a platform devices. The platform device allows to pass rproc_vdev_data platform data to specify properties that are stored in the rproc_vdev structure. Such approach will allow to preserve legacy remoteproc virtio device creation but also to probe the device using device tree mechanism. remoteproc_virtio.c update: - Add rproc_virtio_driver platform driver. The probe ops replaces the rproc_rvdev_add_device function. - All reference to the rvdev->dev has been updated to rvdev-pdev->dev. - rproc_rvdev_release is removed as associated to the rvdev device. - The use of rvdev->kref counter is replaced by get/put_device on the remoteproc virtio platform device. - The vdev device no longer increments rproc device counter. increment/decrement is done in rproc_virtio_probe/rproc_virtio_remove function in charge of the vrings allocation/free. remoteproc_core.c update: Migrate from the rvdev device to the rvdev platform device. From this patch, when a vdev resource is found in the resource table the remoteproc core register a platform device. Signed-off-by: NArnaud Pouliquen <arnaud.pouliquen@foss.st.com> Link: https://lore.kernel.org/r/20220921135044.917140-5-arnaud.pouliquen@foss.st.comSigned-off-by: NMathieu Poirier <mathieu.poirier@linaro.org>
-
- 11 8月, 2022 1 次提交
-
-
由 Xuan Zhuo 提交于
Rename the member len in the structure rpoc_vring to num. And remove 'in bytes' from the comment of it. This is misleading. Because this actually refers to the size of the virtio vring to be created. The unit is not bytes. Signed-off-by: NXuan Zhuo <xuanzhuo@linux.alibaba.com> Message-Id: <20220624025621.128843-2-xuanzhuo@linux.alibaba.com> Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
-
- 12 3月, 2022 2 次提交
-
-
由 Suman Anna 提交于
The rproc_shutdown() function is currently not returning any error code, and any failures within rproc_stop() are not passed back to the users. Change the signature to return a success value back to the callers. The remoteproc sysfs and cdev interfaces are also updated to return back this status to userspace. Signed-off-by: NSuman Anna <s-anna@ti.com> Signed-off-by: NBjorn Andersson <bjorn.andersson@linaro.org> Link: https://lore.kernel.org/r/20220213201246.25952-2-s-anna@ti.com
-
由 Suman Anna 提交于
The rproc_da_to_va() API is an exported function, so move its declaration from the remoteproc local remoteproc_internal.h to the public remoteproc.h file. This will allow drivers outside of the remoteproc folder to be able to use this API. Signed-off-by: NSuman Anna <s-anna@ti.com> Signed-off-by: NDave Gerlach <d-gerlach@ti.com> [adjusted line numbers to apply] Signed-off-by: NDrew Fustini <dfustini@baylibre.com> Signed-off-by: NBjorn Andersson <bjorn.andersson@linaro.org> Link: https://lore.kernel.org/r/20220308172515.29556-1-dfustini@baylibre.com
-
- 05 3月, 2022 1 次提交
-
-
由 Puranjay Mohan 提交于
The remoteproc framework provides sysfs interfaces for changing the firmware name and for starting/stopping a remote processor through the sysfs files 'state' and 'firmware'. The 'coredump' file is used to set the coredump configuration. The 'recovery' sysfs file can also be used similarly to control the error recovery state machine of a remoteproc. These interfaces are currently allowed irrespective of how the remoteprocs were booted (like remoteproc self auto-boot, remoteproc client-driven boot etc). These interfaces can adversely affect a remoteproc and its clients especially when a remoteproc is being controlled by a remoteproc client driver(s). Also, not all remoteproc drivers may want to support the sysfs interfaces by default. Add support to make the remoteproc sysfs files read only by introducing a state flag 'sysfs_read_only' that the individual remoteproc drivers can set based on their usage needs. The default behavior is to allow the sysfs operations as before. Implement attribute_group->is_visible() to make the sysfs entries read only when 'sysfs_read_only' flag is set. Signed-off-by: NPuranjay Mohan <p-mohan@ti.com> Link: https://lore.kernel.org/r/20220216081224.9956-2-p-mohan@ti.comSigned-off-by: NMathieu Poirier <mathieu.poirier@linaro.org>
-
- 15 10月, 2021 1 次提交
-
-
由 Arnaud Pouliquen 提交于
These both functions are only used by the remoteproc_virtio. There is no reason to expose them in the API. Move the functions in remoteproc_virtio.c Signed-off-by: NArnaud Pouliquen <arnaud.pouliquen@foss.st.com> Signed-off-by: NBjorn Andersson <bjorn.andersson@linaro.org> Link: https://lore.kernel.org/r/20211001101234.4247-4-arnaud.pouliquen@foss.st.com
-
- 29 7月, 2021 1 次提交
-
-
由 Dong Aisheng 提交于
The load_rsc_table was removed since the commit c1d35c1a ("remoteproc: Rename "load_rsc_table" to "parse_fw"") but got added back again by mistake in the below commit: commit b1a17513 ("remoteproc: add vendor resources handling"). The patch fixed a small code indent issue which not worth a separate patch. Fixes: b1a17513 ("remoteproc: add vendor resources handling") Signed-off-by: NDong Aisheng <aisheng.dong@nxp.com> Link: https://lore.kernel.org/r/20210706142156.952794-2-aisheng.dong@nxp.comSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
- 28 5月, 2021 1 次提交
-
-
由 Suman Anna 提交于
Fix all the kernel-doc warnings in various remoteproc core files. Some of them just needed a formatting cleanup change, while others needed the Return statement to be added, or documenting the missed structure elements. Reviewed-by: NMathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: NSuman Anna <s-anna@ti.com> Link: https://lore.kernel.org/r/20210519180304.23563-3-s-anna@ti.comSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
- 18 3月, 2021 6 次提交
-
-
由 Mathieu Poirier 提交于
If it is possible to detach the remote processor, keep an untouched copy of the resource table. That way we can start from the same resource table without having to worry about original values or what elements the startup code has changed when re-attaching to the remote processor. Signed-off-by: NMathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: NArnaud Pouliquen <arnaud.pouliquen@st.com> Link: https://lore.kernel.org/r/20210312162453.1234145-12-mathieu.poirier@linaro.orgSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
由 Mathieu Poirier 提交于
Introduce function rproc_detach() to enable the remoteproc core to release the resources associated with a remote processor without stopping its operation. Signed-off-by: NMathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: NArnaud Pouliquen <arnaud.pouliquen@st.com> Link: https://lore.kernel.org/r/20210312162453.1234145-11-mathieu.poirier@linaro.orgSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
由 Mathieu Poirier 提交于
Add an new detach() operation in order to support scenarios where the remoteproc core is going away but the remote processor is kept operating. This could be the case when the system is rebooted or when the platform driver is removed. Signed-off-by: NMathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: NPeng Fan <peng.fan@nxp.com> Reviewed-by: NArnaud Pouliquen <arnaud.pouliquen@st.com> Link: https://lore.kernel.org/r/20210312162453.1234145-9-mathieu.poirier@linaro.orgSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
由 Mathieu Poirier 提交于
Add a new get_loaded_rsc_table() operation in order to support scenarios where the remoteproc core has booted a remote processor and detaches from it. When re-attaching to the remote processor, the core needs to know where the resource table has been placed in memory. Signed-off-by: NMathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: NArnaud Pouliquen <arnaud.pouliquen@st.com> Link: https://lore.kernel.org/r/20210312162453.1234145-6-mathieu.poirier@linaro.orgSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
由 Mathieu Poirier 提交于
There is a need to know when a remote processor has been attached to rather than booted by the remoteproc core. In order to avoid manipulating two variables, i.e rproc::autonomous and rproc::state, get rid of the former and simply use the newly introduced RPROC_ATTACHED state. Signed-off-by: NMathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: NPeng Fan <peng.fan@nxp.com> Reviewed-by: NArnaud Pouliquen <arnaud.pouliquen@st.com> Link: https://lore.kernel.org/r/20210312162453.1234145-5-mathieu.poirier@linaro.orgSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
由 Mathieu Poirier 提交于
Add a new RPROC_ATTACHED state to take into account scenarios where the remoteproc core needs to attach to a remote processor that is booted by another entity. Signed-off-by: NMathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: NPeng Fan <peng.fan@nxp.com> Reviewed-by: NArnaud Pouliquen <arnaud.pouliquen@st.com> Link: https://lore.kernel.org/r/20210312162453.1234145-4-mathieu.poirier@linaro.orgSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
- 12 3月, 2021 2 次提交
-
-
由 Peng Fan 提交于
Introduce an extra parameter is_iomem to da_to_va, then the caller could take the memory as normal memory or io mapped memory. Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Reviewed-by: NMathieu Poirier <mathieu.poirier@linaro.org> Reported-by: Nkernel test robot <lkp@intel.com> Signed-off-by: NPeng Fan <peng.fan@nxp.com> Link: https://lore.kernel.org/r/1615029865-23312-5-git-send-email-peng.fan@oss.nxp.comSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
由 Peng Fan 提交于
Introduce is_iomem to indicate this piece memory is iomem or not. Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Reviewed-by: NMathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: NPeng Fan <peng.fan@nxp.com> Link: https://lore.kernel.org/r/1615029865-23312-4-git-send-email-peng.fan@oss.nxp.comSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
- 11 12月, 2020 2 次提交
-
-
由 Siddharth Gupta 提交于
This change adds a new kind of core dump mechanism which instead of dumping entire program segments of the firmware, dumps sections of the remoteproc memory which are sufficient to allow debugging the firmware. This function thus uses section headers instead of program headers during creation of the core dump elf. Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Co-developed-by: NRishabh Bhatnagar <rishabhb@codeaurora.org> Signed-off-by: NRishabh Bhatnagar <rishabhb@codeaurora.org> Signed-off-by: NSiddharth Gupta <sidgup@codeaurora.org> Link: https://lore.kernel.org/r/1605819935-10726-3-git-send-email-sidgup@codeaurora.orgSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
由 Siddharth Gupta 提交于
Each remoteproc might have different requirements for coredumps and might want to choose the type of dumps it wants to collect. This change allows remoteproc drivers to specify their own custom dump function to be executed in place of rproc_coredump. If the coredump op is not specified by the remoteproc driver it will be set to rproc_coredump by default. Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: NSiddharth Gupta <sidgup@codeaurora.org> Link: https://lore.kernel.org/r/1605819935-10726-2-git-send-email-sidgup@codeaurora.orgSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
- 26 11月, 2020 1 次提交
-
-
由 Suman Anna 提交于
A new API, rproc_set_firmware() is added to allow the remoteproc platform drivers and remoteproc client drivers to be able to configure a custom firmware name that is different from the default name used during remoteproc registration. This function is being introduced to provide a kernel-level equivalent of the current sysfs interface to remoteproc client drivers, and can only change firmwares when the remoteproc is offline. This allows some remoteproc drivers to choose different firmwares at runtime based on the functionality the remote processor is providing. The TI PRU Ethernet driver will be an example of such usage as it requires to use different firmwares for different supported protocols. Also, update the firmware_store() function used by the sysfs interface to reuse this function to avoid code duplication. Reviewed-by: NRishabh Bhatnagar <rishabhb@codeaurora.org> Signed-off-by: NSuman Anna <s-anna@ti.com> Link: https://lore.kernel.org/r/20201121032042.6195-1-s-anna@ti.comSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
- 14 10月, 2020 1 次提交
-
-
由 Rishabh Bhatnagar 提交于
Currently "default" configuration option means coredumps are enabled. To avoid confusion rename the "default" configuration option to "enabled" and disable collection of dumps by default as doing so makes sense for production devices. Signed-off-by: NRishabh Bhatnagar <rishabhb@codeaurora.org> Link: https://lore.kernel.org/r/1601662144-5964-2-git-send-email-rishabhb@codeaurora.orgSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
- 05 8月, 2020 1 次提交
-
-
由 Siddharth Gupta 提交于
Add the character device interface into remoteproc framework. This interface can be used in order to boot/shutdown remote subsystems and provides a basic ioctl based interface to implement supplementary functionality. An ioctl call is implemented to enable the shutdown on release feature which will allow remote processors to be shutdown when the controlling userspace application crashes or hangs. Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Reviewed-by: NMathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: NRishabh Bhatnagar <rishabhb@codeaurora.org> Signed-off-by: NSiddharth Gupta <sidgup@codeaurora.org> Link: https://lore.kernel.org/r/1596044401-22083-2-git-send-email-sidgup@codeaurora.org [bjorn: s/int32_t/s32/ per checkpatch] Signed-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
- 22 7月, 2020 2 次提交
-
-
由 Rishabh Bhatnagar 提交于
The current coredump implementation uses vmalloc area to copy all the segments. But this might put strain on low memory targets as the firmware size sometimes is in tens of MBs. The situation becomes worse if there are multiple remote processors undergoing recovery at the same time. This patch adds inline coredump functionality that avoids extra memory usage. This requires recovery to be halted until data is read by userspace and free function is called. Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Reviewed-by: NSibi Sankar <sibis@codeaurora.org> Reviewed-by: NMathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: NRishabh Bhatnagar <rishabhb@codeaurora.org> Tested-by: NSibi Sankar <sibis@codeaurora.org> Link: https://lore.kernel.org/r/1594938035-7327-5-git-send-email-rishabhb@codeaurora.orgSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
由 Rishabh Bhatnagar 提交于
Change the segment dump API signature to include size and offset arguments. Refactor the qcom_q6v5_mss driver to use these arguments while copying the segment. Doing this lays the ground work for "inline" coredump functionality being added in the next patch. Tested-by: NSibi Sankar <sibis@codeaurora.org> Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Reviewed-by: NSibi Sankar <sibis@codeaurora.org> Reviewed-by: NMathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: NRishabh Bhatnagar <rishabhb@codeaurora.org> Link: https://lore.kernel.org/r/1594938035-7327-4-git-send-email-rishabhb@codeaurora.orgSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
- 18 7月, 2020 1 次提交
-
-
由 Mathieu Poirier 提交于
Make function rproc_resource_cleanup() public so that it can be used by platform drivers when allocating resources to be used by a detached remote processor. Acked-by: NArnaud Pouliquen <arnaud.pouliquen@st.com> Signed-off-by: NMathieu Poirier <mathieu.poirier@linaro.org> Link: https://lore.kernel.org/r/20200714200445.1427257-8-mathieu.poirier@linaro.orgSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
- 17 7月, 2020 3 次提交
-
-
由 Mathieu Poirier 提交于
This patch prevents the firmware image name from being displayed when the remoteproc core is attaching to a remote processor. This is needed needed since there is no guarantee about the nature of the firmware image that is loaded by the external entity. Signed-off-by: NMathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: NArnaud Pouliquen <arnaud.pouliquen@st.com> Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Tested-by: NArnaud Pouliquen <arnaud.pouliquen@st.com> Link: https://lore.kernel.org/r/20200714195035.1426873-10-mathieu.poirier@linaro.orgSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
由 Mathieu Poirier 提交于
Add an new attach() operation in order to properly deal with scenarios where the remoteproc core needs to attach to a remote processor that has been booted by another entity. Signed-off-by: NMathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Tested-by: NArnaud Pouliquen <arnaud.pouliquen@st.com> Link: https://lore.kernel.org/r/20200714195035.1426873-3-mathieu.poirier@linaro.orgSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
由 Mathieu Poirier 提交于
Add a new RPROC_DETACHED state to take into account scenarios where the remoteproc core needs to attach to a remote processor that is booted by another entity. Signed-off-by: NMathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Tested-by: NArnaud Pouliquen <arnaud.pouliquen@st.com> Link: https://lore.kernel.org/r/20200714195035.1426873-2-mathieu.poirier@linaro.orgSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
- 13 5月, 2020 1 次提交
-
-
由 Gustavo A. R. Silva 提交于
The current codebase makes use of the zero-length array language extension to the C90 standard, but the preferred mechanism to declare variable-length types such as these ones is a flexible array member[1][2], introduced in C99: struct foo { int stuff; struct boo array[]; }; By making use of the mechanism above, we will get a compiler warning in case the flexible array does not occur last in the structure, which will help us prevent some kind of undefined behavior bugs from being inadvertently introduced[3] to the codebase from now on. Also, notice that, dynamic memory allocations won't be affected by this change: "Flexible array members have incomplete type, and so the sizeof operator may not be applied. As a quirk of the original implementation of zero-length arrays, sizeof evaluates to zero."[1] sizeof(flexible-array-member) triggers a warning because flexible array members have incomplete type[1]. There are some instances of code in which the sizeof operator is being incorrectly/erroneously applied to zero-length arrays and the result is zero. Such instances may be hiding some bugs. So, this work (flexible-array member conversions) will also help to get completely rid of those sorts of issues. This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732 ("cxgb3/l2t: Fix undefined behaviour") Signed-off-by: NGustavo A. R. Silva <gustavoars@kernel.org> Link: https://lore.kernel.org/r/20200507191943.GA16033@embeddedorSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
- 23 4月, 2020 1 次提交
-
-
由 Loic Pallardy 提交于
On some SoC architecture, it is needed to enable HW like clock, bus, regulator, memory region... before loading co-processor firmware. This patch introduces prepare and unprepare ops to execute platform specific function before firmware loading and after stop execution. Signed-off-by: NLoic Pallardy <loic.pallardy@st.com> Signed-off-by: NSuman Anna <s-anna@ti.com> Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Reviewed-by: NMathieu Poirier <mathieu.poirier@linaro.org> Link: https://lore.kernel.org/r/20200417002036.24359-2-s-anna@ti.comSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
- 21 4月, 2020 2 次提交
-
-
由 Paul Cercueil 提交于
Add API functions devm_rproc_alloc() and devm_rproc_add(), which behave like rproc_alloc() and rproc_add() respectively, but register their respective cleanup function to be called on driver detach. Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: NPaul Cercueil <paul@crapouillou.net> Link: https://lore.kernel.org/r/20200417170040.174319-2-paul@crapouillou.netSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
由 Mathieu Poirier 提交于
For cases where @firmware is declared "const char *", use function kstrdup_const() to avoid needlessly creating another copy on the heap. Suggested-by: NBjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: NMathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: NAlex Elder <elder@linaro.org> Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Link: https://lore.kernel.org/r/20200420231601.16781-2-mathieu.poirier@linaro.orgSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
- 20 4月, 2020 1 次提交
-
-
由 Clement Leger 提交于
This function allows drivers to correctly setup the coredump output elf information. Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Reviewed-by: NMathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: NClement Leger <cleger@kalray.eu> Link: https://lore.kernel.org/r/20200410102433.2672-2-cleger@kalray.euSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
- 26 3月, 2020 5 次提交
-
-
由 Bjorn Andersson 提交于
Introduce generic support for handling kernel panics in remoteproc drivers, in order to allow operations needed for aiding in post mortem system debugging, such as flushing caches etc. The function can return a number of milliseconds needed by the remote to "settle" and the core will wait the longest returned duration before returning from the panic handler. Reviewed-by: NMathieu Poirier <mathieu.poirier@linaro.org> Link: https://lore.kernel.org/r/20200324052904.738594-3-bjorn.andersson@linaro.orgSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
由 Clement Leger 提交于
Now that remoteproc can load an elf64, coredump elf class should be the same as the loaded elf class. In order to do that, add a elf_class field to rproc with default values. If an elf is loaded successfully, this field will be updated with the loaded elf class. Then, the coredump core code has been modified to use the generic elf macro in order to create an elf file with correct class. Reviewed-by: NMathieu Poirier <mathieu.poirier@linaro.org> Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: NClement Leger <cleger@kalray.eu> Link: https://lore.kernel.org/r/20200302093902.27849-9-cleger@kalray.euSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
由 Clement Leger 提交于
elf64 entry is defined as a u64. Since boot_addr is used to store the elf entry point, change boot_addr type to u64 to support both elf32 and elf64. In the same time, fix users that were using this variable. Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: NClement Leger <cleger@kalray.eu> Link: https://lore.kernel.org/r/20200302093902.27849-4-cleger@kalray.eu [bjorn: Fixes up return type of rproc_get_boot_addr()] Signed-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
由 Clement Leger 提交于
Now that rproc_da_to_va uses a size_t for length, use a size_t for len field of rproc_mem_entry. Function used to create such structures now takes a size_t instead of int to allow full size range to be handled. Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Reviewed-by: NMathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: NClement Leger <cleger@kalray.eu> Link: https://lore.kernel.org/r/20200302093902.27849-3-cleger@kalray.euSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
由 Clement Leger 提交于
With upcoming changes in elf loader for elf64 support, section size will be a u64. When used with da_to_va, this will potentially lead to overflow if using the current "int" type for len argument. Change da_to_va prototype to use a size_t for len and fix all users of this function. Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Reviewed-by: NMathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: NClement Leger <cleger@kalray.eu> Link: https://lore.kernel.org/r/20200302093902.27849-2-cleger@kalray.euSigned-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
- 30 6月, 2019 1 次提交
-
-
由 Clement Leger 提交于
In order to allow rproc backend to handle vendor resources such as in OpenAMP, add a handle_rsc hook. This hook allow the rproc backends to handle vendor resources as they like. The hook will be called only for vendor resources and should return RSC_HANDLED on successful resource handling, RSC_IGNORED if resource was ignored, or a negative value on error. Signed-off-by: NClement Leger <cleger@kalray.eu> Signed-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
- 21 2月, 2019 2 次提交
-
-
由 Loic Pallardy 提交于
Commit 7e83cab824a87e83cab824a8 ("remoteproc: Modify recovery path to use rproc_{start,stop}()") replaces rproc_{shutdown,boot}() with rproc_{stop,start}(), which skips destroy the virtio device at stop but re-initializes it again at start. Issue is that struct virtio_dev is not correctly reinitialized like done at initial allocation thanks to kzalloc() and kobject is considered as already initialized by kernel. That is due to the fact struct virtio_dev is allocated and released at vdev resource handling level managed and virtio device is registered and unregistered at rproc subdevices level. Moreover kernel documentation mentions that device struct must be zero initialized before calling device_initialize(). This patch disentangles struct virtio_dev from struct rproc_vdev as the two struct don't have the same life-cycle. struct virtio_dev is now allocated on rproc_start() and released on rproc_stop(). This patch applies on top of patch remoteproc: create vdev subdevice with specific dma memory pool [1] [1]: https://patchwork.kernel.org/patch/10755781/ Fixes: 7e83cab8 ("remoteproc: Modify recovery path to use rproc_{start,stop}()") Reported-by: NXiang Xiao <xiaoxiang781216@gmail.com> Signed-off-by: NLoic Pallardy <loic.pallardy@st.com> Signed-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-
由 Loic Pallardy 提交于
This patch creates a dedicated vdev subdevice for each vdev declared in firmware resource table and associates carveout named "vdev%dbuffer" (with %d vdev index in resource table) if any as dma coherent memory pool. Then vdev subdevice is used as parent for virtio device. Signed-off-by: NLoic Pallardy <loic.pallardy@st.com> Signed-off-by: NBjorn Andersson <bjorn.andersson@linaro.org>
-