[PATCH v4 7/8] media: staging/imx: Improve pipeline searching

2019-05-03 Thread Steve Longerbeam
Export find_pipeline_pad(), renaming to imx_media_pipeline_pad(), and extend its functionality to allow searching for video devices in the enabled pipeline in addition to sub-devices. As part of this: - Rename imx_media_find_mipi_csi2_channel() to imx_media_pipeline_csi2_channel(). - Remove im

[PATCH v4 3/8] media: staging/imx: Move add_video_device into capture_device_register

2019-05-03 Thread Steve Longerbeam
Move imx_media_add_video_device() into imx_media_capture_device_register(). Also the former has no error conditions to convert to void. Signed-off-by: Steve Longerbeam --- drivers/staging/media/imx/imx-ic-prpencvf.c | 5 - drivers/staging/media/imx/imx-media-capture.c | 3 +++ drivers/st

[PATCH v4 8/8] media: staging/imx: Don't set driver data for v4l2_dev

2019-05-03 Thread Steve Longerbeam
The media device is already available via multiple methods, there is no need to set driver data for v4l2_dev to the media device. In imx_media_link_notify(), get media device from link->graph_obj.mdev. In imx_media_capture_device_register(), get media device from v4l2_dev->mdev. Signed-off-by: S

[PATCH v4 6/8] media: staging/imx: Re-organize modules

2019-05-03 Thread Steve Longerbeam
Re-organize modules, and which objects are linked into those modules, so that: - imx6-media (renamed from imx-media) is the media driver module for imx5/6 only, and has no symbol exports. - imx6-media-csi (renamed from imx-media-csi) is the subdev driver module for imx5/6 CSI. It is now linke

[PATCH v4 2/8] media: staging/imx: Pass device to alloc/free_dma_buf

2019-05-03 Thread Steve Longerbeam
Allocate and free a DMA coherent buffer in imx_media_alloc/free_dma_buf() from the given device. This allows DMA alloc and free using a device that is backed by real hardware, which for the imx5/6/7 CSI is the CSI unit, and for the internal IPU sub-devices, is the parent IPU. Signed-off-by: Steve

[PATCH v4 4/8] Revert "media: imx: Set capture compose rectangle in capture_device_set_format"

2019-05-03 Thread Steve Longerbeam
Rvert this commit, as imx_media_capture_device_set_format() will be removed. The arguments to mx_media_mbus_fmt_to_pix_fmt() and imx_media_capture_device_set_format() in imx7_csi_set_fmt() are also reverted. This reverts commit 5964cbd8692252615370b77eb96764dd70c2f837. Signed-off-by: Steve Longer

[PATCH v4 5/8] media: staging/imx: Remove capture_device_set_format

2019-05-03 Thread Steve Longerbeam
Don't propagate the source pad format to the connected capture device. It's now the responsibility of userspace to call VIDIOC_S_FMT on the capture device to ensure the capture format and compose rectangle are compatible with the connected source. To check this, validate the capture format with the

[PATCH v4 1/8] media: staging/imx: Switch to sync registration for IPU subdevs

2019-05-03 Thread Steve Longerbeam
Because the IPU sub-devices VDIC and IC are not present in the device-tree, platform devices were created for them instead. This allowed these sub-devices to be added to the media device's async notifier and registered asynchronously along with the other sub-devices that do have a device-tree prese

RFC: kpc2000 driver naming

2019-05-03 Thread Matt Sickler
Hello, Recently Greg KH posted the first set of drivers for our PCIe device (kpc2000) and shortly after that I posted the kpc2000_dma driver. I was wondering about naming / structure standards in the Linux kernel. First, a real quick background on these devices: Daktronics makes a PCIe card

[PATCH 4/4] staging: iio: ad7150: clean up of comments

2019-05-03 Thread Melissa Wen
General cleaning of comments to remove useless information or improve description. Signed-off-by: Melissa Wen --- drivers/staging/iio/cdc/ad7150.c | 11 ++- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/drivers/staging/iio/cdc/ad7150.c b/drivers/staging/iio/cdc/ad7150.c i

[PATCH 3/4] staging: iio: ad7150: simplify i2c SMBus return treatment

2019-05-03 Thread Melissa Wen
Since i2c_smbus_write_byte_data returns no-positive value, this commit making the treatment of its return value less verbose. Signed-off-by: Melissa Wen --- drivers/staging/iio/cdc/ad7150.c | 10 +++--- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/drivers/staging/iio/cdc/ad7

[PATCH 1/4] staging: iio: ad7150: organize registers definition

2019-05-03 Thread Melissa Wen
Use the suffix REG to make the register addresses clear and indentation to highlight field names. Signed-off-by: Melissa Wen --- drivers/staging/iio/cdc/ad7150.c | 75 1 file changed, 37 insertions(+), 38 deletions(-) diff --git a/drivers/staging/iio/cdc/ad7150.

[PATCH 2/4] staging: iio: ad7150: use FIELD_GET and GENMASK

2019-05-03 Thread Melissa Wen
Use the bitfield macro FIELD_GET, and GENMASK to do the shift and mask in one go. This makes the code more readable than explicit masking followed by a shift. Signed-off-by: Melissa Wen --- drivers/staging/iio/cdc/ad7150.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/

[PATCH 0/4] staging: iio: ad7150: improve driver readability

2019-05-03 Thread Melissa Wen
This patchset solves readability issues in AD7150 code, such as clarify register and mask definition, fashion improvement of mask uses, reduce tedious operation and useless comments. Melissa Wen (4): staging: iio: ad7150: organize registers definition staging: iio: ad7150: use FIELD_GET and GE

Re: [PATCH v3 08/10] staging: octeon-ethernet: support of_get_mac_address new ERR_PTR error

2019-05-03 Thread Dan Carpenter
On Fri, May 03, 2019 at 09:07:30PM +0200, Petr Štetiar wrote: > Dan Carpenter [2019-05-03 13:34:56]: > > Hi, > > > On Fri, May 03, 2019 at 09:56:05AM +0200, Petr Štetiar wrote: > > > There was NVMEM support added to of_get_mac_address, so it could now > > > return NULL and ERR_PTR encoded error

[PATCH] Staging: rtl8723bs: os_dep: Fix switch-case indentation error

2019-05-03 Thread Puranjay Mohan
Fix indentation for switch-case statements to fix following checkpatch.pl Error: ERROR: switch and case should be at the same indent Signed-off-by: Puranjay Mohan --- .../staging/rtl8723bs/os_dep/ioctl_linux.c| 442 +- 1 file changed, 221 insertions(+), 221 deletions(-) diff

Re: [PATCH v3 08/10] staging: octeon-ethernet: support of_get_mac_address new ERR_PTR error

2019-05-03 Thread Petr Štetiar
Dan Carpenter [2019-05-03 13:34:56]: Hi, > On Fri, May 03, 2019 at 09:56:05AM +0200, Petr Štetiar wrote: > > There was NVMEM support added to of_get_mac_address, so it could now > > return NULL and ERR_PTR encoded error values, so we need to adjust all > > current users of of_get_mac_address to

[PATCH v6 5/5] dt-bindings: imx-ocotp: Add i.MX8MM compatible

2019-05-03 Thread Bryan O'Donoghue
Add compatible for i.MX8MM as per arch/arm64/boot/dts/freescale/imx8mm.dtsi Signed-off-by: Bryan O'Donoghue Cc: Rob Herring Reviewed-by: Leonard Crestez --- Documentation/devicetree/bindings/nvmem/imx-ocotp.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindin

[PATCH v6 4/5] nvmem: imx-ocotp: Add i.MX8MM support

2019-05-03 Thread Bryan O'Donoghue
This patch adds support to burn the fuses on the i.MX8MM. https://www.nxp.com/webapp/Download?colCode=IMX8MMRM The i.MX8MM is similar to i.MX6 processors in terms of addressing and clock setup. The documentation specifies 60 discreet OTP registers but, the fusemap address space encompasses up to

[PATCH v6 2/5] nvmem: imx-ocotp: Ensure WAIT bits are preserved when setting timing

2019-05-03 Thread Bryan O'Donoghue
The i.MX6 and i.MX8 both have a bit-field spanning bits 27:22 called the WAIT field. The WAIT field according to the documentation for both parts "specifies time interval between auto read and write access in one time program. It is given in number of ipg_clk periods." This patch ensures that the

[PATCH v6 3/5] nvmem: imx-ocotp: Change TIMING calculation to u-boot algorithm

2019-05-03 Thread Bryan O'Donoghue
The RELAX field of the OCOTP block is turning out as a zero on i.MX8MM. This messes up the subsequent re-load of the fuse shadow registers. After some discussion with people @ NXP its clear we have missed a trick here in Linux. The OCOTP fuse programming time has a physical minimum 'burn time' th

[PATCH v6 1/5] nvmem: imx-ocotp: Elongate OCOTP_CTRL ADDR field to eight bits

2019-05-03 Thread Bryan O'Donoghue
i.MX6 defines OCOTP_CTRLn:ADDR as seven bit address-field with a one bit RSVD0 field, i.MX7 defines OCOTP_CTRLn:ADDR as a four bit address-field with a four bit RSVD0 field. i.MX8 defines the OCOTP_CTRLn:ADDR bit-field as a full range eight bits. i.MX6 and i.MX7 should return zero for their respe

[RESEND PATCH v6 0/5] Add i.MX8MM OCOTP support

2019-05-03 Thread Bryan O'Donoghue
V6 RESEND: - Adding Greg to sender list. Greg looks like you are the right person to apply this. - Adding de...@driverdev.osuosl.org to sender list - History: https://www.spinics.net/lists/arm-kernel/msg723454.html https://www.spinics.net/lists/arm-kernel/msg723321.html https://www.spinic

[PATCH v5] staging: octeon-ethernet: support of_get_mac_address new ERR_PTR error

2019-05-03 Thread Petr Štetiar
There was NVMEM support added to of_get_mac_address, so it could now return ERR_PTR encoded error values, so we need to adjust all current users of of_get_mac_address to this new fact. Signed-off-by: Petr Štetiar --- Changes since v3: * IS_ERR_OR_NULL -> IS_ERR Changes since v4: * I've

[PATCH v4 08/10] staging: octeon-ethernet: support of_get_mac_address new ERR_PTR error

2019-05-03 Thread Petr Štetiar
There was NVMEM support added to of_get_mac_address, so it could now return ERR_PTR encoded error values, so we need to adjust all current users of of_get_mac_address to this new fact. Signed-off-by: Petr Štetiar --- Changes since v3: * IS_ERR_OR_NULL -> IS_ERR drivers/staging/octeon/ether

Re: [Intel-gfx] [PATCH] dma-buf: add struct dma_buf_attach_info v2

2019-05-03 Thread Koenig, Christian
Am 03.05.19 um 14:09 schrieb Daniel Vetter: > [CAUTION: External Email] > > On Fri, May 03, 2019 at 02:05:47PM +0200, Christian König wrote: >> Am 30.04.19 um 19:31 schrieb Russell King - ARM Linux admin: >>> On Tue, Apr 30, 2019 at 01:10:02PM +0200, Christian König wrote: Add a structure for

Re: [Intel-gfx] [PATCH] dma-buf: add struct dma_buf_attach_info v2

2019-05-03 Thread Daniel Vetter
On Fri, May 03, 2019 at 02:05:47PM +0200, Christian König wrote: > Am 30.04.19 um 19:31 schrieb Russell King - ARM Linux admin: > > On Tue, Apr 30, 2019 at 01:10:02PM +0200, Christian König wrote: > > > Add a structure for the parameters of dma_buf_attach, this makes it much > > > easier > > > to

Re: [PATCH] dma-buf: add struct dma_buf_attach_info v2

2019-05-03 Thread Christian König
Am 30.04.19 um 19:31 schrieb Russell King - ARM Linux admin: On Tue, Apr 30, 2019 at 01:10:02PM +0200, Christian König wrote: Add a structure for the parameters of dma_buf_attach, this makes it much easier to add new parameters later on. I don't understand this reasoning. What are the "new par

Re: [PATCH v3 08/10] staging: octeon-ethernet: support of_get_mac_address new ERR_PTR error

2019-05-03 Thread Dan Carpenter
On Fri, May 03, 2019 at 09:56:05AM +0200, Petr Štetiar wrote: > There was NVMEM support added to of_get_mac_address, so it could now > return NULL and ERR_PTR encoded error values, so we need to adjust all > current users of of_get_mac_address to this new fact. Which commit added NVMEM support? I

[PATCH v3 08/10] staging: octeon-ethernet: support of_get_mac_address new ERR_PTR error

2019-05-03 Thread Petr Štetiar
There was NVMEM support added to of_get_mac_address, so it could now return NULL and ERR_PTR encoded error values, so we need to adjust all current users of of_get_mac_address to this new fact. Signed-off-by: Petr Štetiar --- drivers/staging/octeon/ethernet.c | 2 +- 1 file changed, 1 insertion(

Re: [PATCH] staging: most: cdev: fix chrdev_region leak in mod_exit

2019-05-03 Thread Eugeniu Rosca
On Thu, May 02, 2019 at 07:39:20PM +0200, Greg Kroah-Hartman wrote: > On Wed, Apr 24, 2019 at 09:23:43PM +0200, Eugeniu Rosca wrote: > > From: Suresh Udipi > > > > It looks like v4.18-rc1 commit [0] which upstreams mld-1.8.0 > > commit [1] missed to fix the memory leak in mod_exit function. > >