[PATCH 3/9] ARM: dts: bcm2711: Add firmware usb reset node

2020-06-08 Thread Nicolas Saenz Julienne
Now that the reset driver exposing Raspberry Pi 4's firmware based USB reset routine is available, let's add the device tree node exposing it. Signed-off-by: Nicolas Saenz Julienne --- arch/arm/boot/dts/bcm2711-rpi-4-b.dts | 5 + 1 file changed, 5 insertions(+) diff --git a/arch/arm/boot

[PATCH 8/9] Revert "firmware: raspberrypi: Introduce vl805 init routine"

2020-06-08 Thread Nicolas Saenz Julienne
This reverts commit fbbc5ff3f7f9f4cad562e530ae2cf5d8964fe6d3. The vl805 routine has moved to drivers/reset/reset-raspberrypi-usb.c Signed-off-by: Nicolas Saenz Julienne --- drivers/firmware/raspberrypi.c | 61 -- include/soc/bcm2835/raspberrypi-firmware.h | 7

[PATCH 6/9] Revert "USB: pci-quirks: Add Raspberry Pi 4 quirk"

2020-06-08 Thread Nicolas Saenz Julienne
This reverts commit c65822fef4adc0ba40c37a47337376ce75f7a7bc. The initialization of Raspberry Pi 4's USB chip is now handled through a reset controller. No need to directly call the firmware routine trough a pci quirk. Signed-off-by: Nicolas Saenz Julienne --- drivers/firmware/Kconfig

[PATCH 1/9] dt-bindings: reset: Add a binding for the RPi Firmware USB reset

2020-06-08 Thread Nicolas Saenz Julienne
The firmware running on the RPi VideoCore can be used to reset and initialize the board's xHCI controller. The reset controller is passed to the PCI device through the DT, hence this binding. Signed-off-by: Nicolas Saenz Julienne --- .../arm/bcm/raspberrypi,bcm2835-firmware.yaml | 21

[PATCH 9/9] Revert "PCI: brcmstb: Wait for Raspberry Pi's firmware when present"

2020-06-08 Thread Nicolas Saenz Julienne
This reverts commit 44331189f9082c7e659697bbac1747db3def73e7. Now that the VL805 init routine is run through a reset controller driver the dependencies are being taken care of by the device core. No need to do it manually here. Signed-off-by: Nicolas Saenz Julienne --- drivers/pci/controller

[PATCH 5/9] usb: xhci-pci: Add support for reset controllers

2020-06-08 Thread Nicolas Saenz Julienne
Some atypical users of xhci-pci might need to manually reset their xHCI controller before starting the HCD setup. Check if a reset controller device is available to the PCI bus and trigger a reset. Signed-off-by: Nicolas Saenz Julienne --- drivers/usb/host/xhci-pci.c | 9 + 1 file

[PATCH 4/9] ARM: dts: bcm2711: Add reset controller to xHCI node

2020-06-08 Thread Nicolas Saenz Julienne
The chip is hardwired to the board's PCIe bus and needs to be properly setup trough a firmware routine after a PCI fundamental reset. Pass the reset controller phandle that takes care of triggering the initialization to the relevant PCI device. Signed-off-by: Nicolas Saenz Julienne --- arch/arm

[PATCH 06/50] staging: mmal-vchiq: Fixup vchiq-mmal include ordering

2020-06-23 Thread Nicolas Saenz Julienne
From: Dave Stevenson There were dependencies on including the headers in the correct order. Fix up the headers so that they include the other headers that they depend on themselves. Signed-off-by: Dave Stevenson Signed-off-by: Jacopo Mondi Signed-off-by: Nicolas Saenz Julienne --- drivers

[PATCH 02/50] staging: mmal-vchiq: Allocate and free components as required

2020-06-23 Thread Nicolas Saenz Julienne
From: Dave Stevenson The existing code assumed that there would only ever be 4 components, and never freed the entries once used. Allow arbitrary creation and destruction of components. Signed-off-by: Dave Stevenson Signed-off-by: Jacopo Mondi Signed-off-by: Nicolas Saenz Julienne

[PATCH 24/50] staging: vchi: Get rid of effect less expression

2020-06-23 Thread Nicolas Saenz Julienne
It was probably there to trick compilers into ignoring unused variables, which isn't needed in Linux. Signed-off-by: Nicolas Saenz Julienne --- drivers/staging/vc04_services/interface/vchiq_arm/vchiq_shim.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/staging/vc04_services

[PATCH 12/50] staging: vchi: Get rid of all useless callback reasons

2020-06-23 Thread Nicolas Saenz Julienne
They are neither produced nor expected, so just delete them. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchi/vchi_common.h | 40 ++- 1 file changed, 3 insertions(+), 37 deletions(-) diff --git a/drivers/staging/vc04_services/interface/vchi

[PATCH 19/50] staging: vchi: Get rid of unnecessary defines

2020-06-23 Thread Nicolas Saenz Julienne
Those defines aren't used by anyone. Get rid of them. Signed-off-by: Nicolas Saenz Julienne --- drivers/staging/vc04_services/interface/vchi/vchi.h | 11 --- drivers/staging/vc04_services/vchiq-mmal/mmal-vchiq.c | 1 - 2 files changed, 12 deletions(-) diff --git a/drivers/staging

[PATCH 50/50] staging: vchiq: Move vchiq.h into include directory

2020-06-23 Thread Nicolas Saenz Julienne
To make the separation clear between vchiq's header files and vchiq.h, which is to be used by services and is the 'public' API, move it into a dedicated includes directory. Signed-off-by: Nicolas Saenz Julienne --- drivers/staging/vc04_services/Makefile| 2 +- drivers

[PATCH 45/50] staging: vchi: Move vchi_queue_kernel_message() into vchiq

2020-06-23 Thread Nicolas Saenz Julienne
We can't really merge it with vchiq_queue_message() as it has internal users that will not benefit from the retry mechanism vchiq_queue_kernel_message() uses. So, for the sake of getting rid of vchi, move it into vchiq. Signed-off-by: Nicolas Saenz Julienne --- .../bcm2835-audio/bcm2835-vchiq.c

[PATCH 44/50] staging: vchi: Get rid of vchi_bulk_queue_transmit()

2020-06-23 Thread Nicolas Saenz Julienne
Its vchiq counterpart, vchiq_bulk_transmit() is only used by vchi. We can then merge both functions by moving vchi_bulk_queue_transmit()'s retry mechanism into vchiq_bulk_transmit() and let services call the later. Signed-off-by: Nicolas Saenz Julienne --- .../bcm2835-audio/bcm2835-vchiq.c

[PATCH 01/50] staging: bcm2835: Break MMAL support out from camera

2020-06-23 Thread Nicolas Saenz Julienne
for the ISP driver to use it as well. The only modification to the existing mmal code is the introduction of EXPORT_SYMBOL() for symbols required by bcm2835-camera and the addition of the module author and licenses. Signed-off-by: Jacopo Mondi Signed-off-by: Nicolas Saenz Julienne --- drivers

[PATCH 42/50] staging: vchiq: Move definitions only used by core into core header

2020-06-23 Thread Nicolas Saenz Julienne
vchiq_if.h is used by service consumers and only the exported API should be present. Move the rest of definitions, which were not exported by the way, to vchiq_core.h where they belong. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm/vchiq_core.h | 22

[PATCH 36/50] staging: vchi: Rework vchi_msg_hold() to match vchiq_msg_hold()

2020-06-23 Thread Nicolas Saenz Julienne
The services have access to struct vchiq_header's internals, so we can let them get the data pointer. This pretty much makes both functions exactly the same, which will allow us to make a switch to vchiq_msg_hold() further down the road. Signed-off-by: Nicolas Saenz Julienne --- .../staging

[PATCH 35/50] staging: vchiq: Pass vchiq's message when holding a message

2020-06-23 Thread Nicolas Saenz Julienne
and directly pass struct vchiq_header, which is what ultimately vchiq consumes when handling callback messages. Signed-off-by: Nicolas Saenz Julienne --- .../vc04_services/interface/vchi/vchi.h | 14 ++- .../interface/vchiq_arm/vchiq_shim.c | 25 ++- 2 files

[PATCH 37/50] staging: vchiq: Unify fourcc definition mechanisms

2020-06-23 Thread Nicolas Saenz Julienne
There is already enough duplication with regard to fourcc generation in the kernel. Let's at least use the same macro all over the vchiq ecosystem. Signed-off-by: Nicolas Saenz Julienne --- drivers/staging/vc04_services/bcm2835-audio/bcm2835-vchiq.c | 2 +- .../vc04_services/bcm2835-audio

[PATCH 26/50] staging: vchiq: Move message queue into struct vchiq_service

2020-06-23 Thread Nicolas Saenz Julienne
to match vchiq's user_service message queue, which could be merged with this one in the future. Signed-off-by: Nicolas Saenz Julienne --- drivers/staging/vc04_services/Makefile| 1 - .../interface/vchiq_arm/vchiq_core.c | 46 .../interface/vchiq_arm/vchiq_core.h

[PATCH 40/50] staging: vchiq: Get rid of unnecessary definitions in vchiq_if.h

2020-06-23 Thread Nicolas Saenz Julienne
Those functions don't actually exist, nor have any use, nor the macros. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm/vchiq_if.h | 17 - 1 file changed, 17 deletions(-) diff --git a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_if.h b

[PATCH 47/50] staging: vchiq: Move conditional barrier definition into vchiq_core.h

2020-06-23 Thread Nicolas Saenz Julienne
The barrier is only used by core code. So keep the barrier definition in the core header. Signed-off-by: Nicolas Saenz Julienne --- .../vc04_services/interface/vchiq_arm/vchiq.h| 11 --- .../vc04_services/interface/vchiq_arm/vchiq_core.h | 12 2 files changed, 12

[PATCH 41/50] staging: vchiq: Make vchiq_add_service() local

2020-06-23 Thread Nicolas Saenz Julienne
The function is being exported although there is no use for it outside of vchiq's core code. Keep it local then. Signed-off-by: Nicolas Saenz Julienne --- drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c | 3 +-- drivers/staging/vc04_services/interface/vchiq_arm/vchiq_if.h | 3

[PATCH 49/50] staging: vchiq: Move defines into core header

2020-06-23 Thread Nicolas Saenz Julienne
Those are only used in the core vchiq code, while present in vchiq's 'public' API header. Move them into the right place. Signed-off-by: Nicolas Saenz Julienne --- drivers/staging/vc04_services/interface/vchiq_arm/vchiq.h| 5 - .../staging/vc04_services/interface/vchiq_arm/vchiq_core.h

[PATCH 46/50] staging: vchiq: Get rid of vchi

2020-06-23 Thread Nicolas Saenz Julienne
-off-by: Nicolas Saenz Julienne --- drivers/staging/vc04_services/Makefile| 1 - .../bcm2835-audio/bcm2835-vchiq.c | 24 +-- .../vc04_services/bcm2835-audio/bcm2835.h | 1 - .../vc04_services/interface/{vchi => }/TODO | 0 .../vc04_services/interface/vchi/vch

[PATCH 48/50] staging: vchiq: Use vchiq.h as the main header file for services

2020-06-23 Thread Nicolas Saenz Julienne
This used to be vchiq_if.h but vchiq.h is more concise for an include file that will hopefully be in the future in the includes directory. Signed-off-by: Nicolas Saenz Julienne --- .../vc04_services/bcm2835-audio/bcm2835.h | 2 +- .../vc04_services/interface/vchiq_arm/vchiq.h | 107

[PATCH 43/50] staging: vchi: Get rid of vchi_bulk_queue_receive()

2020-06-23 Thread Nicolas Saenz Julienne
Its vchiq counterpart, vchiq_bulk_receive() is only used by vchi. We can then merge both functions by moving vchi_bulk_queue_receive()'s retry mechanism into vchiq_bulk_receive() and let services call the later. Signed-off-by: Nicolas Saenz Julienne --- .../vc04_services/interface/vchi/vchi.h

[PATCH 39/50] staging: vchi: Don't include vchiq_core.h

2020-06-23 Thread Nicolas Saenz Julienne
This file is internal to vchiq. Signed-off-by: Nicolas Saenz Julienne --- drivers/staging/vc04_services/interface/vchiq_arm/vchiq_shim.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_shim.c b/drivers/staging/vc04_services/interface

[PATCH 38/50] staging: vchi: Get rid of struct vchiq_instance forward declaration

2020-06-23 Thread Nicolas Saenz Julienne
It's already forward declared in vchiq_if.h. So no need to insist Signed-off-by: Nicolas Saenz Julienne --- drivers/staging/vc04_services/interface/vchi/vchi.h | 7 --- 1 file changed, 7 deletions(-) diff --git a/drivers/staging/vc04_services/interface/vchi/vchi.h b/drivers/staging

[PATCH 31/50] staging: vchi: Get rid of vchiq_shim's message callback

2020-06-23 Thread Nicolas Saenz Julienne
code in the end. Signed-off-by: Nicolas Saenz Julienne --- .../bcm2835-audio/bcm2835-vchiq.c | 20 ++--- .../vc04_services/interface/vchi/vchi.h | 9 +- .../interface/vchi/vchi_common.h | 12 --- .../interface/vchiq_arm/vchiq_shim.c | 42

[PATCH 30/50] staging: vchiq: Export vchiq_msg_queue_push

2020-06-23 Thread Nicolas Saenz Julienne
vchiq consumer drivers may need to use this function in order to get the benefits of vchiq's per service message queueing mechanism. Signed-off-by: Nicolas Saenz Julienne --- drivers/staging/vc04_services/interface/vchiq_arm/vchiq_if.h | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers

[PATCH 32/50] staging: vchiq: Don't use a typedef for vchiq_callback

2020-06-23 Thread Nicolas Saenz Julienne
Linux coding style says to avoid typdefs. Signed-off-by: Nicolas Saenz Julienne --- .../staging/vc04_services/interface/vchi/vchi.h| 5 - .../vc04_services/interface/vchiq_arm/vchiq_if.h | 14 -- 2 files changed, 12 insertions(+), 7 deletions(-) diff --git a/drivers

[PATCH 33/50] staging: vchi: Use struct vchiq_service_params

2020-06-23 Thread Nicolas Saenz Julienne
For initialization, vchi has its own params structure, which is then translated to vchiq's params structure. They are essentially the same, so lets directly use vchiq's. Signed-off-by: Nicolas Saenz Julienne --- .../bcm2835-audio/bcm2835-vchiq.c | 9 + .../vc04_services

[PATCH 25/50] staging: vchiq: Introduce vchiq_validate_params()

2020-06-23 Thread Nicolas Saenz Julienne
When adding a new service validate the configuration parameters provided, and remove unnecessary checks in vchi, now that we have validated service's config. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm/vchiq_core.c | 15 +++ .../interface/vchiq_arm

[PATCH 34/50] staging: vchi: Get rid of struct vchi_service

2020-06-23 Thread Nicolas Saenz Julienne
The structure only contains a single parameter, which is the underlying vchiq handle. Get rid of the struct and directly pass the handle around. Signed-off-by: Nicolas Saenz Julienne --- .../bcm2835-audio/bcm2835-vchiq.c | 23 ++--- .../vc04_services/interface/vchi/vchi.h | 25

[PATCH 20/50] staging: vc04_services: Get rid of vchi_cfg.h

2020-06-23 Thread Nicolas Saenz Julienne
Nothing in it is being used. Signed-off-by: Nicolas Saenz Julienne --- .../vc04_services/interface/vchi/vchi.h | 1 - .../vc04_services/interface/vchi/vchi_cfg.h | 238 -- 2 files changed, 239 deletions(-) delete mode 100644 drivers/staging/vc04_services/interface

[PATCH 27/50] staging: vchiq: Get rid of vchiq_util.h

2020-06-23 Thread Nicolas Saenz Julienne
The header file only provides other includes. Move the relevant includes to their respective C files and delete it for good. Signed-off-by: Nicolas Saenz Julienne --- .../vc04_services/interface/vchiq_arm/vchiq.h | 1 - .../interface/vchiq_arm/vchiq_2835_arm.c | 1 + .../interface

[PATCH 28/50] staging: vchi: Expose struct vchi_service

2020-06-23 Thread Nicolas Saenz Julienne
This will make further changes easier. The struct will ultimately disappear. Signed-off-by: Nicolas Saenz Julienne --- drivers/staging/vc04_services/interface/vchi/vchi.h| 10 +++--- .../vc04_services/interface/vchiq_arm/vchiq_shim.c | 7 --- 2 files changed, 7 insertions

[PATCH 29/50] staging: vchiq: Export vchiq_get_service_userdata()

2020-06-23 Thread Nicolas Saenz Julienne
This is for service's callbacks to get their private data. Signed-off-by: Nicolas Saenz Julienne --- drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.c b/drivers

[PATCH 18/50] staging: vchi_common: Get rid of all unused definitions

2020-06-23 Thread Nicolas Saenz Julienne
There is a series of structures and enums defined but never used. Get rid of them. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchi/vchi_common.h | 65 --- 1 file changed, 65 deletions(-) diff --git a/drivers/staging/vc04_services/interface/vchi

[PATCH 23/50] staging: vchi: Use vchiq's enum vchiq_reason

2020-06-23 Thread Nicolas Saenz Julienne
enum vchi_callback_reason maps 1:1 to enum vchiq_reason, in an effort to simplify things, let's use the later, and get rid of the extra indirection. Signed-off-by: Nicolas Saenz Julienne --- .../bcm2835-audio/bcm2835-vchiq.c | 5 +-- .../interface/vchi/vchi_common.h

[PATCH 22/50] staging: vchi: Use enum vchiq_bulk_mode instead of vchi's transmission flags

2020-06-23 Thread Nicolas Saenz Julienne
vchi has a set of transfer flags which almost map 1:1 to vchiq's own transfer modes. For the sake of simplicity let's use the later and delete vchi's. Signed-off-by: Nicolas Saenz Julienne --- .../bcm2835-audio/bcm2835-vchiq.c | 2 +- .../vc04_services/bcm2835-audio/bcm2835.h

[PATCH 21/50] staging: vchi: Get rid of flags argument in vchi_msg_hold()

2020-06-23 Thread Nicolas Saenz Julienne
All users are ignoring the flags argument. So for the sake of simplicity delete it. Signed-off-by: Nicolas Saenz Julienne --- .../vc04_services/bcm2835-audio/bcm2835-vchiq.c | 3 +-- drivers/staging/vc04_services/interface/vchi/vchi.h | 1 - .../vc04_services/interface/vchiq_arm

[PATCH 16/50] staging: vc04_services: bcm2835-audio: Use vchi_msg_hold()

2020-06-23 Thread Nicolas Saenz Julienne
() instead. Signed-off-by: Nicolas Saenz Julienne --- .../bcm2835-audio/bcm2835-vchiq.c | 25 +++ 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/drivers/staging/vc04_services/bcm2835-audio/bcm2835-vchiq.c b/drivers/staging/vc04_services/bcm2835-audio/bcm2835

[PATCH 11/50] staging: vchiq_arm: Add a matching unregister call

2020-06-23 Thread Nicolas Saenz Julienne
Signed-off-by: Nicolas Saenz Julienne --- drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c index 28

[PATCH 15/50] staging: vchi: Unify struct shim_service and struct vchi_service_handle

2020-06-23 Thread Nicolas Saenz Julienne
struct shim_service into struvt vchi_service, which is more consistent with the rest of the exposed API. Signed-off-by: Nicolas Saenz Julienne --- .../bcm2835-audio/bcm2835-vchiq.c | 24 +++ .../vc04_services/interface/vchi/vchi.h | 27 .../interface/vchiq_arm

[PATCH 13/50] staging: vchi: Get rid of vchi_msg_peek()

2020-06-23 Thread Nicolas Saenz Julienne
-by: Nicolas Saenz Julienne --- .../vc04_services/interface/vchi/vchi.h | 12 .../interface/vchiq_arm/vchiq_shim.c | 64 --- .../interface/vchiq_arm/vchiq_util.c | 12 .../interface/vchiq_arm/vchiq_util.h | 1 - 4 files changed, 89 deletions

[PATCH 14/50] staging: vchi: Get rid of struct vchi_instance_handle

2020-06-23 Thread Nicolas Saenz Julienne
The idea behind this was to create an opaque handle to struct vchiq_instance. This can be achieved without creating a new type by means of a forward declaration of struct vchiq_instance. This saves us from a lot of useless casting and overall simplifies code. Signed-off-by: Nicolas Saenz

[PATCH 17/50] staging: vchi: Get rid of vchi_msg_dequeue()

2020-06-23 Thread Nicolas Saenz Julienne
Nobody uses it. Get rid of it. Signed-off-by: Nicolas Saenz Julienne --- .../vc04_services/interface/vchi/vchi.h | 7 .../interface/vchiq_arm/vchiq_shim.c | 39 --- 2 files changed, 46 deletions(-) diff --git a/drivers/staging/vc04_services/interface/vchi

[PATCH 03/50] staging: mmal-vchiq: Avoid use of bool in structures

2020-06-23 Thread Nicolas Saenz Julienne
From: Dave Stevenson Fixes up a checkpatch error "Avoid using bool structure members because of possible alignment issues". Signed-off-by: Dave Stevenson Signed-off-by: Jacopo Mondi Signed-off-by: Nicolas Saenz Julienne --- drivers/staging/vc04_services/vchiq-mmal/mmal-vchiq.c

[PATCH 10/50] staging: mmal-vchiq: Fix formatting errors in mmal_parameters.h

2020-06-23 Thread Nicolas Saenz Julienne
From: Naushir Patuck No functional changes in this commit. - Remove erroneous whitespace. - Remove _t postfix label on structs and enums. Signed-off-by: Naushir Patuck Signed-off-by: Jacopo Mondi Signed-off-by: Nicolas Saenz Julienne --- .../bcm2835-camera/bcm2835-camera.c | 2

[PATCH 00/50] staging: vchiq: Getting rid of the vchi/vchiq split

2020-06-23 Thread Nicolas Saenz Julienne
camera Naushir Patuck (1): staging: mmal-vchiq: Fix formatting errors in mmal_parameters.h Nicolas Saenz Julienne (39): staging: vchi: Get rid of all useless callback reasons staging: vchi: Get rid of vchi_msg_peek() staging: vchi: Get rid of struct vchi_instance_handle staging: vchi

[PATCH 09/50] staging: mmal-vchiq: If the VPU returns an error, don't negate it

2020-06-23 Thread Nicolas Saenz Julienne
. Signed-off-by: Dave Stevenson Signed-off-by: Jacopo Mondi Signed-off-by: Nicolas Saenz Julienne --- drivers/staging/vc04_services/vchiq-mmal/mmal-vchiq.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/staging/vc04_services/vchiq-mmal/mmal-vchiq.c b/drivers

[PATCH 05/50] staging: mmal-vchiq: Make a mmal_buf struct for passing parameters

2020-06-23 Thread Nicolas Saenz Julienne
for the struct, and pass the appropriate members. Signed-off-by: Dave Stevenson Signed-off-by: Jacopo Mondi Signed-off-by: Nicolas Saenz Julienne --- .../bcm2835-camera/bcm2835-camera.c | 64 +++ .../vc04_services/vchiq-mmal/mmal-common.h| 5 ++ .../vc04_services/vchiq

[PATCH 08/50] staging: mmal-vchiq: Always return the param size from param_get

2020-06-23 Thread Nicolas Saenz Julienne
-off-by: Jacopo Mondi Signed-off-by: Nicolas Saenz Julienne --- drivers/staging/vc04_services/vchiq-mmal/mmal-vchiq.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/staging/vc04_services/vchiq-mmal/mmal-vchiq.c b/drivers/staging/vc04_services/vchiq-mmal/mmal-vchiq.c

[PATCH 07/50] staging: mmal-vchiq: Fix client_component for 64 bit kernel

2020-06-23 Thread Nicolas Saenz Julienne
are already held in an array per VCHI instance, so use the array index as the client_component handle to avoid having to create a new IDR for this purpose. Signed-off-by: Dave Stevenson Signed-off-by: Jacopo Mondi Signed-off-by: Nicolas Saenz Julienne --- drivers/staging/vc04_services/vchiq-mmal/mmal

[PATCH 04/50] staging: mmal-vchiq: Make timeout a defined parameter

2020-06-23 Thread Nicolas Saenz Julienne
From: Dave Stevenson The timeout period for VPU communications is a useful thing to extend when debugging. Set it via a define, rather than a magic number buried in the code. Signed-off-by: Dave Stevenson Signed-off-by: Jacopo Mondi Signed-off-by: Nicolas Saenz Julienne --- drivers/staging

Re: [PATCH v4 5/5] usb: xhci-pci: Add reset controller support

2020-06-15 Thread Nicolas Saenz Julienne
On Fri, 2020-06-12 at 19:08 +0200, Marek Vasut wrote: > On 6/12/20 6:46 PM, Nicolas Saenz Julienne wrote: > > Some atypical users of xhci-pci might need to manually reset their xHCI > > controller before starting the HCD setup. Check if a reset controller > > device is ava

Re: [PATCH v4 2/3] clk: bcm: Add BCM2711 DVP driver

2020-06-15 Thread Nicolas Saenz Julienne
e > Cc: Stephen Boyd > Cc: Rob Herring > Cc: linux-...@vger.kernel.org > Cc: devicet...@vger.kernel.org > Reviewed-by: Stephen Boyd > Signed-off-by: Maxime Ripard > --- Reviewed-by: Nicolas Saenz Julienne Regards, Nicolas signature.asc Description: This is a digitally signed message part

Re: [PATCH v4 3/3] ARM: dts: bcm2711: Add HDMI DVP

2020-06-15 Thread Nicolas Saenz Julienne
On Thu, 2020-06-11 at 11:23 +0200, Maxime Ripard wrote: > Now that we have a driver for the DVP, let's add its DT node. > > Signed-off-by: Maxime Ripard > --- I can take this patch, but I guess the rest should go trough the clock tree. Is it OK with you? Regards, Nicolas signature.asc

[RFC v2] usb: xhci: add Immediate Data Transfer support

2019-02-05 Thread Nicolas Saenz Julienne
us ones. I can't seem to find a device that'll perform transfers with such small packet sizes. The implementation takes into account that the 8 byte buffers provided by the URB will never cross a 64KB boundary. Signed-off-by: Nicolas Saenz Julienne --- Chages since first RFC: - Got rid o

Re: [RFC v2] usb: xhci: add Immediate Data Transfer support

2019-02-06 Thread Nicolas Saenz Julienne
Hi Felipe, thanks for the review! On Wed, 2019-02-06 at 08:35 +0200, Felipe Balbi wrote: > Hi, > > Nicolas Saenz Julienne writes: > > diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host/xhci-ring.c > > index 40fa25c4d041..a4efbe62a1a3 100644 > > --- a/d

Re: [PATCH 00/16] staging: vchiq: dead code removal & misc fixes

2018-11-20 Thread Nicolas Saenz Julienne
On Tue, 2018-11-20 at 10:57 +0100, Greg KH wrote: > On Sun, Nov 18, 2018 at 04:55:49PM +0100, Stefan Wahren wrote: > > Hi Nicolas, > > > > > Nicolas Saenz Julienne hat am 14. > > > November 2018 um 13:59 geschrieben: > > > > > > > > &

[PATCH v3] usb: hub: add retry routine after intr URB submit error

2018-11-20 Thread Nicolas Saenz Julienne
already take care of this issue, the implementation was inspired from usbhid/hid_core.c's. Signed-off-by: Nicolas Saenz Julienne --- v3: As per Oliver's request: - Take care of race condition between disconnect and irq v2: as per Alan's and Oliver's comments: - Rename timer - Delete

[PATCH 02/16] staging: vchiq_arm: rework close/remove_service IOCTLS

2018-11-20 Thread Nicolas Saenz Julienne
The implementation of both IOCTLS was the same except for one function call. This joins both implementations and updates the code to avoid unneeded indentations. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm/vchiq_arm.c | 66 +++ 1 file changed, 24

[PATCH 03/16] staging: vchiq_shim: delete vchi_service_create

2018-11-20 Thread Nicolas Saenz Julienne
No one is using the API neither in the actual staging tree nor in the downstream tree (https://github.com/raspberrypi/linux). Signed-off-by: Nicolas Saenz Julienne --- .../vc04_services/interface/vchi/vchi.h | 5 --- .../interface/vchiq_arm/vchiq_shim.c | 32

[PATCH 14/16] staging: vchiq_arm: rework probe and init functions

2018-11-20 Thread Nicolas Saenz Julienne
Moves the allocation of a chardev region and class creation to the init function of the driver since those functions are meant to be run on a per driver basis, as opposed to the code run in the probe function which is run in a per device basis. Signed-off-by: Nicolas Saenz Julienne

[PATCH 15/16] staging: vchiq_arm: fix open/release cdev functions

2018-11-20 Thread Nicolas Saenz Julienne
Both functions checked the minor number of the cdev prior running the code. This was useless since the number of devices is already limited by alloc_chrdev_region. This removes the check and reindents the code where relevant. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm

[PATCH 16/16] staging: vchiq: add more tasks to the TODO list

2018-11-20 Thread Nicolas Saenz Julienne
The TODO list was missing some tasks needed before upstreaming the device. Signed-off-by: Nicolas Saenz Julienne --- .../staging/vc04_services/interface/vchi/TODO | 42 +++ 1 file changed, 42 insertions(+) diff --git a/drivers/staging/vc04_services/interface/vchi/TODO b

[PATCH 11/16] staging: vchiq: use completions instead of semaphores

2018-11-20 Thread Nicolas Saenz Julienne
are semantically more explicit in this case. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm/vchiq_arm.c | 60 ++- .../interface/vchiq_arm/vchiq_core.c | 100 +- .../interface/vchiq_arm/vchiq_core.h | 26 ++--- .../interface/vchiq_arm

[PATCH 12/16] staging: vchiq_util: get rid of unneeded memory barriers

2018-11-20 Thread Nicolas Saenz Julienne
All the memory operations featured in this file modify/access memory that is only accessed by the CPU. So we can assume that all the memory barrier handling done by the completion routines is good enough for us. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm/vchiq_util.c

[PATCH 08/16] staging: vchiq_core: remove unnecessary safety checks in vchiq_init_state

2018-11-20 Thread Nicolas Saenz Julienne
changed in between functions, making the checks useless. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm/vchiq_core.c | 59 --- 1 file changed, 59 deletions(-) diff --git a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.c b/drivers/staging

[PATCH 13/16] staging: vchiq_core: fix logic redundancy in parse_open

2018-11-20 Thread Nicolas Saenz Julienne
We update sync to reflect that the firmware version is compatible with that option. We don't need to check both of them again further down the code. Signed-off-by: Nicolas Saenz Julienne --- .../staging/vc04_services/interface/vchiq_arm/vchiq_core.c| 4 +--- 1 file changed, 1 insertion

[PATCH 05/16] staging: vchiq_arm: get rid of vchi_mh.h

2018-11-20 Thread Nicolas Saenz Julienne
The concept of VCHI_MEM_HANDLE_T is introduced by this header file and was meant to be used with bulk transfers. After a quick look in vchiq_core.c it is pretty clear that it actually accomplishes nothing nor alters the bulk transfers in any way. Signed-off-by: Nicolas Saenz Julienne

[PATCH 10/16] staging: vchiq_core: don't add a wmb() before remote_event_signal()

2018-11-20 Thread Nicolas Saenz Julienne
It's the first thing remote_event_signal() does. Signed-off-by: Nicolas Saenz Julienne --- .../staging/vc04_services/interface/vchiq_arm/vchiq_core.c| 4 1 file changed, 4 deletions(-) diff --git a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.c b/drivers/staging

[PATCH 07/16] staging: vchiq-core: get rid of is_master distinction

2018-11-20 Thread Nicolas Saenz Julienne
". There seems to be an option to switch roles in vchiq. Which nobody is using nor is properly implemented. So we get rid of the "is_master == 1" option, and all the related code. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm/vchiq_2835_arm.c | 12 +- .../in

[PATCH 09/16] staging: vchiq_core: do not initialize semaphores twice

2018-11-20 Thread Nicolas Saenz Julienne
vchiq_init_state() initialises a series of semaphores to then call remote_event_create() on the same semaphores, which initializes them again. We get rid of the second initialization. Signed-off-by: Nicolas Saenz Julienne --- .../vc04_services/interface/vchiq_arm/vchiq_core.c| 11

[PATCH 06/16] staging: vchiq_arm: rework vchiq_ioc_copy_element_data

2018-11-20 Thread Nicolas Saenz Julienne
ll the elements into memory as long as they fit". The resulting function is shorter and simpler. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm/vchiq_arm.c | 89 +++ 1 file changed, 31 insertions(+), 58 deletions(-) diff --git a/drivers/staging/vc0

[PATCH 01/16] staging: vchiq_core: rework vchiq_get_config

2018-11-20 Thread Nicolas Saenz Julienne
The function is overly complicated for what it's ultimately achieving. It's simply filling up a structure. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm/vchiq_arm.c | 12 .../interface/vchiq_arm/vchiq_core.c | 30 +-- .../interface

[PATCH 00/16] staging: vchiq: dead code removal & misc fixes

2018-11-20 Thread Nicolas Saenz Julienne
ree semaphore to completion patches (commit 11) - Update probe/init commit message (commit 14) - Update TODO commit message and clean up (commit 16) - Fix spelling on some of the patches === Nicolas Saenz Julienne (16): staging: vchiq_core: rework vchiq_get_config staging: vchiq_arm: rew

[PATCH 04/16] staging: vchiq_arm: use list_for_each_entry when accessing bulk_waiter_list

2018-11-20 Thread Nicolas Saenz Julienne
The resulting code is way more readeable and intuitive compared to plain list_for_each. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm/vchiq_arm.c | 52 ++- 1 file changed, 16 insertions(+), 36 deletions(-) diff --git a/drivers/staging/vc04_services

[PATCH] firmware: arm_sdei: fix wrong of_node_put() in init function

2018-11-26 Thread Nicolas Saenz Julienne
e again. This patch removes the unwarranted call to of_node_put(). Fixes: ad6eb31ef903 ("firmware: arm_sdei: Add driver for Software Delegated Exceptions") Signed-off-by: Nicolas Saenz Julienne --- drivers/firmware/arm_sdei.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers

[PATCH] drm/panel: rpi-touchscreen: Add backlight support

2018-12-14 Thread Nicolas Saenz Julienne
This patch exposes backlight control into userspace by creating a backlight device instead of directly accessing the PWM registers. The backlight driver can't go on a separate file as it shares the I2C bus & address with the panel. Signed-off-by: Nicolas Saenz Julienne --- .../drm/panel/p

[PATCH] xhci: fix 'broken_suspend' placement in struct xchi_hcd

2018-12-17 Thread Nicolas Saenz Julienne
n AMD SNPS 3.0 xHC") Reported-by: Oliver Neukum Signed-off-by: Nicolas Saenz Julienne --- drivers/usb/host/xhci.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/usb/host/xhci.h b/drivers/usb/host/xhci.h index c3515bad5dbb..011dd45f8718 100644 --- a/driver

Re: [PATCH] staging: vchiq: rework remove_event handling

2018-12-12 Thread Nicolas Saenz Julienne
On Tue, 2018-12-11 at 15:20 +0100, Arnd Bergmann wrote: > On Tue, Dec 11, 2018 at 1:36 PM Nicolas Saenz Julienne > wrote: > > On Mon, 2018-12-10 at 22:11 +0100, Arnd Bergmann wrote: > > > @@ -447,26 +444,26 @@ remote_event_wait(VCHIQ_STATE_T *state, > &

[PATCH 0/3] staging: vchiq: fix completion routines & semaphores

2018-12-12 Thread Nicolas Saenz Julienne
and gets rid of vchiq_killable.h. I took into account Arnd's commit to avoid merge conflicts. [1] https://www.spinics.net/lists/arm-kernel/msg694422.html === Nicolas Saenz Julienne (3): staging: vchiq: switch to wait_for_completion_killable staging: vchiq_2835_arm: quit using custom

[PATCH 1/3] staging: vchiq: switch to wait_for_completion_killable

2018-12-12 Thread Nicolas Saenz Julienne
letions instead of semaphores") Reported-by: Arnd Bergmann Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm/vchiq_arm.c | 21 +-- .../interface/vchiq_arm/vchiq_core.c | 21 +-- .../interface/vchiq_arm/vchiq_util.c

[PATCH 3/3] staging: vchiq: delete vchiq_killable.h

2018-12-12 Thread Nicolas Saenz Julienne
There are no users for that header file. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm/vchiq_2835_arm.c | 1 - .../interface/vchiq_arm/vchiq_arm.c | 1 - .../interface/vchiq_arm/vchiq_connected.c | 1 - .../interface/vchiq_arm/vchiq_core.c | 1

[PATCH 2/3] staging: vchiq_2835_arm: quit using custom down_interruptible()

2018-12-12 Thread Nicolas Saenz Julienne
vchi_killable.h overrides down_interruptible() by implementing a function similar to down_killable(). To make things simpler we turn calls to down_interruptible() into kernel's implementation of down_killable(). Signed-off-by: Nicolas Saenz Julienne --- .../staging/vc04_services/interface

[PATCH RFC 16/18] staging: vchiq_arm: rework probe and init functions

2018-10-26 Thread Nicolas Saenz Julienne
Some operations performed in the probe function should have been implemented in the init function. Namely class and dev region creations. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm/vchiq_arm.c | 71 --- 1 file changed, 45 insertions(+), 26

[PATCH RFC 18/18] staging: vchiq: add more tasks to the TODO list

2018-10-26 Thread Nicolas Saenz Julienne
The more the better. Signed-off-by: Nicolas Saenz Julienne --- .../staging/vc04_services/interface/vchi/TODO | 46 ++- 1 file changed, 44 insertions(+), 2 deletions(-) diff --git a/drivers/staging/vc04_services/interface/vchi/TODO b/drivers/staging/vc04_services/interface/vchi

[PATCH RFC 13/18] staging: vchiq_core: use completions instead of semaphores

2018-10-26 Thread Nicolas Saenz Julienne
are semantically more explicit in this case. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm/vchiq_arm.c | 2 +- .../interface/vchiq_arm/vchiq_core.c | 94 +-- .../interface/vchiq_arm/vchiq_core.h | 26 ++--- 3 files changed, 61 insertions(+), 61

[PATCH RFC 00/18] staging: vchiq: remove dead code & misc fixes

2018-10-26 Thread Nicolas Saenz Julienne
-next, and was tested on a RPIv3B+ with audio, video and running vchiq_test. Regards, Nicolas === Nicolas Saenz Julienne (18): staging: vchiq_core: rework vchiq_get_config staging: vchiq_arm: rework close/remove_service IOCTLS staging: vchiq_shim: delete vchi_service_create stagning

[PATCH RFC 17/18] staging: vchiq_arm: fix open/release cdev functions

2018-10-26 Thread Nicolas Saenz Julienne
Both functions checked the minor number of the cdev prior running the code. This was useless since the number of devices is already limited by alloc_chrdev_region. This removes the check and reindents the code where relevant. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm

[PATCH RFC 15/18] stagning: vchiq_core: fix logic redundancy in parse_open

2018-10-26 Thread Nicolas Saenz Julienne
We update sync to reflect that the firmware version is compatible with that option. We don't need to check both of them again further down the code. Signed-off-by: Nicolas Saenz Julienne --- .../staging/vc04_services/interface/vchiq_arm/vchiq_core.c| 4 +--- 1 file changed, 1 insertion

[PATCH RFC 12/18] staging: vchiq_util: use completions instead of semaphores

2018-10-26 Thread Nicolas Saenz Julienne
are semantically more explicit in this case. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm/vchiq_util.c | 16 .../interface/vchiq_arm/vchiq_util.h | 6 +++--- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/drivers/staging

[PATCH RFC 11/18] staging: vchiq_arm: use completions instead of semaphores

2018-10-26 Thread Nicolas Saenz Julienne
are semantically more explicit in this case. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm/vchiq_arm.c | 58 ++- 1 file changed, 31 insertions(+), 27 deletions(-) diff --git a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c b/drivers/staging

[PATCH RFC 09/18] staging: vchiq_core: do not initialize semaphores twice

2018-10-26 Thread Nicolas Saenz Julienne
vchiq_init_state() initialises a series of semaphores to then call remote_event_create() on the same semaphores, which initializes them again. Signed-off-by: Nicolas Saenz Julienne --- .../staging/vc04_services/interface/vchiq_arm/vchiq_core.c | 5 - 1 file changed, 5 deletions(-) diff

[PATCH RFC 14/18] staging: vchiq_util: get rid of unneeded memory barriers

2018-10-26 Thread Nicolas Saenz Julienne
All the memory operations featured in this file modify/access memory that is only accessed by the CPU. So we can assume that all the memory barrier handling done by the completion routines is good enough for us. Signed-off-by: Nicolas Saenz Julienne --- .../interface/vchiq_arm/vchiq_util.c

<    4   5   6   7   8   9   10   11   12   >