dwc2 isochronous transfers issues

2018-12-04 Thread Andrzej Pietrasiewicz
Hi All, I have recently noticed a problem with dwc2 and audio gadget. The expected behavior: The uac2 function acts as a kind of a pass-through. For example to play audio from USB host on an Odroid U3 the following command is issued at the host: aplay -D plughw:CARD=Gadget,DEV=0

[PATCHv4] usb: gadget: f_fs: Allow scatter-gather buffers

2018-11-14 Thread Andrzej Pietrasiewicz
and this patch takes advantage of this capability: if the requested buffer is larger than PAGE_SIZE and the UDC allows scatter-gather operation, then the buffer is allocated with vmalloc and a scatterlist describing it is created and passed to usb request. Signed-off-by: Andrzej Pietrasiewicz --- v4

[PATCHv3] usb: gadget: f_fs: Allow scatter-gather buffers

2018-11-13 Thread Andrzej Pietrasiewicz
and this patch takes advantage of this capability: if the requested buffer is larger than PAGE_SIZE and the UDC allows scatter-gather operation, then the buffer is allocated with vmalloc and a scatterlist describing it is created and passed to usb request. Signed-off-by: Andrzej Pietrasiewicz --- v3

[PATCHv2] usb: gadget: f_fs: Allow scatter-gather buffers

2018-11-09 Thread Andrzej Pietrasiewicz
and this patch takes advantage of this capability: if the requested buffer is larger than PAGE_SIZE and the UDC allows scatter-gather operation, then the buffer is allocated with vmalloc and a scatterlist describing it is created and passed to usb request. Signed-off-by: Andrzej Pietrasiewicz --- v2

[PATCH] usb: gadget: f_fs: Allow scatter-gather buffers

2018-11-06 Thread Andrzej Pietrasiewicz
and this patch takes advantage of this capability: if the requested buffer is larger than PAGE_SIZE and the UDC allows scatter-gather operation, then the buffer is allocated with vmalloc and a scatterlist describing it is created and passed to usb request. Signed-off-by: Andrzej Pietrasiewicz --- @Felipe

[PATCH] usb: gadget: f_fs: Allow scatter-gather buffers

2018-11-06 Thread Andrzej Pietrasiewicz
and this patch takes advantage of this capability: if the requested buffer is larger than PAGE_SIZE and the UDC allows scatter-gather operation, then the buffer is allocated with vmalloc and a scatterlist describing it is created and passed to usb request. Signed-off-by: Andrzej Pietrasiewicz --- drivers

Re: [PATCH v2 1/3] usb: gadget: ccid: add support for USB CCID Gadget Device

2018-05-28 Thread Andrzej Pietrasiewicz
W dniu 28.05.2018 o 11:32, Marcus Folkesson pisze: > Hi Andrzej, > > Thank you for reviewing. > > On Mon, May 28, 2018 at 11:12:27AM +0200, Andrzej Pietrasiewicz wrote: >> W dniu 28.05.2018 o 10:38, Marcus Folkesson pisze: >>> Hi Andrzej, >>> >>> O

Re: [PATCH v2 1/3] usb: gadget: ccid: add support for USB CCID Gadget Device

2018-05-28 Thread Andrzej Pietrasiewicz
W dniu 28.05.2018 o 10:38, Marcus Folkesson pisze: > Hi Andrzej, > > On Mon, May 28, 2018 at 09:04:51AM +0200, Andrzej Pietrasiewicz wrote: >> Mi Marcus, >> >> W dniu 26.05.2018 o 23:19, Marcus Folkesson pisze: >>> Chip Card Interface Device (CCID) protoc

Re: [PATCH v2 1/3] usb: gadget: ccid: add support for USB CCID Gadget Device

2018-05-28 Thread Andrzej Pietrasiewicz
Mi Marcus, W dniu 26.05.2018 o 23:19, Marcus Folkesson pisze: > Chip Card Interface Device (CCID) protocol is a USB protocol that > allows a smartcard device to be connected to a computer via a card > reader using a standard USB interface, without the need for each manufacturer > of smartcards to

Re: [PATCH 2/3] usb: gadget: configfs: Create control_config group

2018-04-17 Thread Andrzej Pietrasiewicz
Hi again, W dniu 17.04.2018 o 09:55, Andrzej Pietrasiewicz pisze: > Hi, > > W dniu 17.04.2018 o 03:17, Jerry Zhang pisze: >> Control_config is a group under gadget that acts > > > >> >> @@ -1461,6 +1499,18 @@ static struct config_

Re: [PATCH 2/3] usb: gadget: configfs: Create control_config group

2018-04-17 Thread Andrzej Pietrasiewicz
Hi, W dniu 17.04.2018 o 03:17, Jerry Zhang pisze: > Control_config is a group under gadget that acts > > @@ -1461,6 +1499,18 @@ static struct config_group *gadgets_make( > if (!gi->composite.gadget_driver.function) > goto err; > > + gi->control_config.c.label =

Re: Handling custom device control requests in userspace

2018-04-06 Thread Andrzej Pietrasiewicz
Hi Jerry, W dniu 04.04.2018 o 02:04, Jerry Zhang pisze: Hi all, I've been looking for a way to handle custom device targeted control requests from userspace. This would allow us to move away from needing kernel patches to implement https://source.android.com/devices/accessories/aoa. It seems

[PATCHv4 0/2] dwc3 on XU3

2017-10-09 Thread Andrzej Pietrasiewicz
in phy_calibrate() commit (as suggested by Kishon) - rebased onto v4.14-rc4 Changes since v2: - exported the "calibrate_phy" symbol Changes since v1: - added calibrate() callback to phy - used calibrate() instead of reset() to trigger the calibration Andrzej Pietrasiewicz (1): drivers

[PATCHv4 1/2] drivers: phy: add calibrate method

2017-10-09 Thread Andrzej Pietrasiewicz
intialization. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/phy/phy-core.c | 15 +++ include/linux/phy/phy.h | 10 ++ 2 files changed, 25 insertions(+) diff --git a/drivers/phy/phy-core.c b/drivers/phy/phy-core.c index a268f4d..b4964b0 100644 --- a/drive

[PATCHv4 2/2] phy: exynos5-usbdrd: Calibrate LOS levels for exynos5420/5800

2017-10-09 Thread Andrzej Pietrasiewicz
mber 2 using xhci-hcd [Also removed unnecessary extra lines in the register macro definitions] Signed-off-by: Vivek Gautam <gautam.vi...@samsung.com> [adapted to use phy_calibrate as entry point] Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/phy/samsung/ph

[PATCHv3 0/2] dwc3 on XU3

2017-10-05 Thread Andrzej Pietrasiewicz
ot; symbol Changes since v1: - added calibrate() callback to phy - used calibrate() instead of reset() to trigger the calibration Andrzej Pietrasiewicz (1): drivers: phy: add calibrate method Vivek Gautam (1): phy: exynos5-usbdrd: Calibrate LOS levels for exynos5420/5800 drivers/phy/

[PATCHv3 1/2] drivers: phy: add calibrate method

2017-10-05 Thread Andrzej Pietrasiewicz
Some quirky UDCs (like dwc3 on exynos) need to have heir phys calibrated e.g. for using super speed. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/phy/phy-core.c | 15 +++ include/linux/phy/phy.h | 10 ++ 2 files changed, 25 insertions(+)

[PATCHv3 2/2] phy: exynos5-usbdrd: Calibrate LOS levels for exynos5420/5800

2017-10-05 Thread Andrzej Pietrasiewicz
mber 2 using xhci-hcd [Also removed unnecessary extra lines in the register macro definitions] Signed-off-by: Vivek Gautam <gautam.vi...@samsung.com> [adapted to use phy_calibrate as entry point] Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/phy/samsung/ph

Re: [PATCHv2 0/2] dwc3 on XU3

2017-10-04 Thread Andrzej Pietrasiewicz
Hi, W dniu 04.10.2017 o 06:22, Kishon Vijay Abraham I pisze: Hi, @Kishon: As far as I understand what you suggest is to move phy_init() and phy_power_on() invocations from dwc3/core.c to xhci-plat, but, to the best of my knowledge, they are needed in device mode, too. What I meant is

Re: [PATCHv2 0/2]

2017-10-03 Thread Andrzej Pietrasiewicz
W dniu 03.10.2017 o 14:59, Andrzej Pietrasiewicz pisze: Hi all, This is the second version of patches in this thread. I have lost the subject of the cover letter. Should be "dwc3 on XU3". I did not resend the series in order not to spam the recipients. Sorry for confusion

[PATCHv2 0/2]

2017-10-03 Thread Andrzej Pietrasiewicz
is to move phy_init() and phy_power_on() invocations from dwc3/core.c to xhci-plat, but, to the best of my knowledge, they are needed in device mode, too. Changes since v1: - added calibrate() callback to phy - used calibrate() instead of reset() to trigger the calibration Andrzej Pietrasiewicz (1

[PATCHv2 1/2] drivers: phy: add calibrate method

2017-10-03 Thread Andrzej Pietrasiewicz
Some quirky UDCs (like dwc3 on exynos) need to have heir phys calibrated e.g. for using super speed. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/phy/phy-core.c | 14 ++ include/linux/phy/phy.h | 10 ++ 2 files changed, 24 insertions(+)

[PATCHv2 2/2] phy: exynos5-usbdrd: Calibrate LOS levels for exynos5420/5800

2017-10-03 Thread Andrzej Pietrasiewicz
mber 2 using xhci-hcd [Also removed unnecessary extra lines in the register macro definitions] Signed-off-by: Vivek Gautam <gautam.vi...@samsung.com> [adapted to use phy_calibrate as entry point] Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/phy/samsung/ph

Re: [PATCH 1/2] ARM: dts: exynos: Add dwc3 SUSPHY quirk

2017-09-22 Thread Andrzej Pietrasiewicz
Hi, W dniu 19.09.2017 o 20:10, Robin Murphy pisze: On 19/09/17 18:40, Krzysztof Kozlowski wrote: On Mon, Sep 18, 2017 at 12:02:13PM +0200, Andrzej Pietrasiewicz wrote: Odroid XU4 board does not enumerate SuperSpeed devices. This patch makes exynos5 series chips use USB SUSPHY quirk, which

Re: [PATCH 2/2] phy: exynos5-usbdrd: Calibrate LOS levels for exynos5420/5800

2017-09-18 Thread Andrzej Pietrasiewicz
Hi, W dniu 18.09.2017 o 14:43, Felipe Balbi pisze: Hi, Andrzej Pietrasiewicz <andrze...@samsung.com> writes: +static int exynos5_usbdrd_phy_reset(struct phy *phy) +{ + struct phy_usb_instance *inst = phy_get_drvdata(phy); + struct exynos5_usbdrd_phy *phy_drd = to_usbdrd_ph

Re: [PATCH 2/2] phy: exynos5-usbdrd: Calibrate LOS levels for exynos5420/5800

2017-09-18 Thread Andrzej Pietrasiewicz
Hi, W dniu 18.09.2017 o 13:27, Andrzej Pietrasiewicz pisze: W dniu 18.09.2017 o 13:06, Kishon Vijay Abraham I pisze: Hi, On Monday 18 September 2017 04:08 PM, Felipe Balbi wrote: Hi, Andrzej Pietrasiewicz <andrze...@samsung.com> writes: From: Vivek Gautam <gautam.vi...@sa

Re: [PATCH 2/2] phy: exynos5-usbdrd: Calibrate LOS levels for exynos5420/5800

2017-09-18 Thread Andrzej Pietrasiewicz
W dniu 18.09.2017 o 13:06, Kishon Vijay Abraham I pisze: Hi, On Monday 18 September 2017 04:08 PM, Felipe Balbi wrote: Hi, Andrzej Pietrasiewicz <andrze...@samsung.com> writes: From: Vivek Gautam <gautam.vi...@samsung.com> Adding phy calibration sequence for USB 3.0 DRD

[PATCH 2/2] phy: exynos5-usbdrd: Calibrate LOS levels for exynos5420/5800

2017-09-18 Thread Andrzej Pietrasiewicz
mber 2 using xhci-hcd [Also removed unnecessary extra lines in the register macro definitions] Signed-off-by: Vivek Gautam <gautam.vi...@samsung.com> [adapted to use phy_reset as entry point] Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/phy/samsung/phy-exyn

[PATCH 1/2] ARM: dts: exynos: Add dwc3 SUSPHY quirk

2017-09-18 Thread Andrzej Pietrasiewicz
Odroid XU4 board does not enumerate SuperSpeed devices. This patch makes exynos5 series chips use USB SUSPHY quirk, which solves the problem. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- arch/arm/boot/dts/exynos54xx.dtsi | 2 ++ 1 file changed, 2 insertions(+) diff

[PATCH 0/2] dwc3 on XU3 and XU4

2017-09-18 Thread Andrzej Pietrasiewicz
only after dwc3_host_init() but phy_set_mode() is called either after of before it. With this patch enumeration happens correctly and a super speed device is recognized as such. Rebased onto v4.13. It also applies cleanly to Felipe's testing/next. Andrzej Pietrasiewicz (1): ARM: dts: exynos: Add

[PATCH] fs: configfs: don't return anything from drop_link

2016-11-28 Thread Andrzej Pietrasiewicz
ompile-tested only! It needs Tested-by from respective subsystems. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- Documentation/filesystems/configfs/configfs.txt | 2 +- drivers/nvme/target/configfs.c | 46 ++--- drivers/target/tar

Re: [PATCH] usb: gadget: uvc: fix returnvar.cocci warnings

2016-11-23 Thread Andrzej Pietrasiewicz
Hi Laurent, Thanks for a reminder. Please see inline. W dniu 22.11.2016 o 18:27, Laurent Pinchart pisze: Hi Andrzej and Julia, Could one of you please submit a patch to fix this ? On Thursday 17 Sep 2015 13:18:04 Andrzej Pietrasiewicz wrote: Hi Julia, W dniu 17.09.2015 o 10:57, Julia

Re: UAS and f_tcm -- is anyone using it?

2016-09-22 Thread Andrzej Pietrasiewicz
W dniu 20.09.2016 o 21:19, John Youn pisze: Hi Sebastian, Andrzej, If possible, could you share how you are using it? Such as in what speed, mode, and with what controllers/platforms and hosts? If you have any other tips on usage I would appreciate it. I'm looking into getting it working

Re: [PATCH] usb: f_mass_storage: test whether thread is running before starting another

2016-04-18 Thread Andrzej Pietrasiewicz
Hi Michał, W dniu 07.04.2016 o 18:40, Michal Nazarewicz pisze: On Thu, 7 Apr 2016, Michal Nazarewicz wrote: This makes me suspect it’s not possible to link a function instance to the same configuration twice, but now that I think about it, I’m not quite sure what would happen if one did:

Re: [patch -target tree] usb: gadget: f_tcm: use after free

2016-03-10 Thread Andrzej Pietrasiewicz
Hi Nicholas, W dniu 10.03.2016 o 06:19, Nicholas A. Bellinger pisze: Hi Andrzej, On Wed, 2016-03-09 at 13:53 +0100, Andrzej Pietrasiewicz wrote: Hi Nicholas, Applying the following patch to re-add the missing assingment as a proper alloc_session callback. diff --git a/drivers/usb

Re: [patch -target tree] usb: gadget: f_tcm: use after free

2016-03-09 Thread Andrzej Pietrasiewicz
Hi Nicholas, W dniu 05.03.2016 o 08:26, Nicholas A. Bellinger pisze: Hi Felipe + usb-gadget folks, On Wed, 2016-03-02 at 13:55 +0200, Felipe Balbi wrote: usb-gadget/tcm: Conversion to percpu_ida tag pre-allocation http://www.spinics.net/lists/target-devel/msg11777.html usb-gadget/tcm:

Re: USB gadgets with configfs hang reboot

2016-01-22 Thread Andrzej Pietrasiewicz
Hi Tony, W dniu 15.01.2016 o 23:48, Tony Lindgren pisze: Hi all, Looks like there's some issue with the USB gadgets and configfs. I'm seeing rmmod of the UDC driver cause a warning and then reboot hangs the system. This happens at least with v4.4, and I've reproduced it with dwc3 and musb so

[PATCHv5 01/18] fs: configfs: Drop unused parameter from configfs_undepend_item()

2015-12-11 Thread Andrzej Pietrasiewicz
From: Krzysztof Opasiak subsys parameter is never used by configfs_undepend_item() so there is no point in passing it to this function. Signed-off-by: Krzysztof Opasiak Cc: Joel Becker Cc: Christoph Hellwig

[PATCHv5 07/18] tcm_usb_gadget: Fix enabled attribute failure

2015-12-11 Thread Andrzej Pietrasiewicz
From: Nicholas Bellinger <n...@linux-iscsi.org> Fix up tcm_usbg_tpg_store_enable() return value to propagate usbg_attach() failure up to user-space if no HDC is found. Reported-by: Andrzej Pietrasiewicz <andrze...@samsung.com> Cc: Andrzej Pietrasiewicz <andrze...@samsung.com

[PATCHv5 17/18] usb: gadget: f_tcm: use usb_gstrings_attach

2015-12-11 Thread Andrzej Pietrasiewicz
Do not directly use file static strings definitions in instances of f_tcm. Instead use usb_gstrings_attach. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/function/f_tcm.c | 18 +++--- 1 file changed, 7 insertions(+), 11 deletions(-) diff

[PATCHv5 06/18] tcm_usb_gadget: Fix nexus leak

2015-12-11 Thread Andrzej Pietrasiewicz
From: Nicholas Bellinger <n...@linux-iscsi.org> This patch adds the missing tcm_usbg_drop_nexus() to properly release tcm_usbg_nexus memory during typical ->fabric_drop_tpg() callback shutdown. Reported-by: Andrzej Pietrasiewicz <andrze...@samsung.com> Cc: Andrzej Pietra

[PATCHv5 05/18] tcm_usb_gadget: Don't strip off nexus WWPN prefix

2015-12-11 Thread Andrzej Pietrasiewicz
OT, so it will not effect host side code. Reported-by: Andrzej Pietrasiewicz <andrze...@samsung.com> Cc: Andrzej Pietrasiewicz <andrze...@samsung.com> Cc: Sebastian Andrzej Siewior <bige...@linutronix.de> Signed-off-by: Nicholas Bellinger <n...@linux-iscsi.org>

[PATCHv5 12/18] usb: gadget: tcm: factor out f_tcm

2015-12-11 Thread Andrzej Pietrasiewicz
Prepare for converting tcm to new function registration interface. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/function/f_tcm.c| 2145 drivers/usb/gadget/function/tcm.h | 132 ++ drivers/usb/gadget/

[PATCHv5 04/18] fs: configfs: Add unlocked version of configfs_depend_item()

2015-12-11 Thread Andrzej Pietrasiewicz
encies, they are not suitable if the other kernel subsystem happens to be another subsystem in configfs, so this patch adds unlocked versions meant for configfs callbacks. Above description has been provided by: Andrzej Pietrasiewicz <andrze...@samsung.com> In configfs_depend_item() we have to

[PATCHv5 15/18] usb: gadget: f_tcm: remove compatibility layer

2015-12-11 Thread Andrzej Pietrasiewicz
There are no old function interface users left. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/function/f_tcm.c | 87 +++-- 1 file changed, 6 insertions(+), 81 deletions(-) diff --git a/drivers/usb/gadget/function/f_tc

[PATCHv5 11/18] usb: gadget: tcm: simplify attribute store function

2015-12-11 Thread Andrzej Pietrasiewicz
Simplify function code. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/legacy/tcm_usb_gadget.c | 22 +++--- 1 file changed, 7 insertions(+), 15 deletions(-) diff --git a/drivers/usb/gadget/legacy/tcm_usb_gadget.c b/drivers/usb/gadget/

[PATCHv5 14/18] usb: gadget: tcm: convert to use new function registration interface

2015-12-11 Thread Andrzej Pietrasiewicz
Convert the only user of old tcm function interface so that the old interface can be removed. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/legacy/Kconfig | 1 + drivers/usb/gadget/legacy/tcm_usb_gadget.c | 62 +--

[PATCHv5 08/18] usb: gadget: tcm: split string definitions into function and device

2015-12-11 Thread Andrzej Pietrasiewicz
Prepare for factoring out f_tcm from a legacy gadget. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/legacy/tcm_usb_gadget.c | 25 + drivers/usb/gadget/legacy/tcm_usb_gadget.h | 3 +-- 2 files changed, 22 insertions(+), 6 del

[PATCHv5 13/18] usb: gadget: f_tcm: convert to new function interface with backward compatibility

2015-12-11 Thread Andrzej Pietrasiewicz
of preprocessor conditional directives. After all users are converted, the old interface can be removed. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/Kconfig | 3 + drivers/usb/gadget/function/Makefile | 2 + drivers/usb/gadget/function/f

[PATCHv5 16/18] usb: gadget: f_tcm: remove redundant singleton

2015-12-11 Thread Andrzej Pietrasiewicz
The only instance is guaranteed with TPG_INSTANCES defined to 1. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/function/f_tcm.c | 9 - drivers/usb/gadget/function/tcm.h | 2 -- 2 files changed, 11 deletions(-) diff --git a/drivers/usb/

[PATCHv5 10/18] usb: gadget: tcm: use strtobool for a boolean value

2015-12-11 Thread Andrzej Pietrasiewicz
Simplify the function. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/legacy/tcm_usb_gadget.c | 10 -- 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/drivers/usb/gadget/legacy/tcm_usb_gadget.c b/drivers/usb/gadget/

[PATCHv5 03/18] fs: configfs: Factor out configfs_find_subsys_dentry()

2015-12-11 Thread Andrzej Pietrasiewicz
From: Krzysztof Opasiak configfs_depend_item() is quite complicated and should be split up into smaller functions. This also allow to share this code with other functions. Signed-off-by: Krzysztof Opasiak Cc: Joel Becker Cc:

[PATCHv5 00/18] Equivalent of tcm_usb_gadget with configfs

2015-12-11 Thread Andrzej Pietrasiewicz
# echo $VENDOR_ID > idVendor # echo $PRODUCT_ID > idProduct # echo 1240.dwc3 > UDC TESTING THE FUNCTION The most basic testing device: run the script above host: see the gadget enumerated Andrzej Pietrasiewicz (11): usb: gadget: tcm: split string definitions

[PATCHv5 09/18] usb: gadget: tcm: follow naming conventions

2015-12-11 Thread Andrzej Pietrasiewicz
Prepare for splitting tcm_usb_gadget into legacy gadget proper and f_tcm. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/legacy/tcm_usb_gadget.c | 28 ++-- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/drive

[PATCHv5 18/18] usb: gadget: f_tcm: add configfs support

2015-12-11 Thread Andrzej Pietrasiewicz
Allow using the tcm function as a component of a gadget composed with ConfigFS. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- Documentation/ABI/testing/configfs-usb-gadget-tcm | 6 ++ drivers/usb/gadget/Kconfig| 14 + drivers/usb/gadget/fu

[PATCHv2] usb: gadget: f_tcm: ignore return value of queue_work

2015-12-10 Thread Andrzej Pietrasiewicz
queue_work() has never returned anything less than zero. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- This patch depends on the series adding configfs support to tcm usb gadget: http://www.spinics.net/lists/target-devel/msg11215.html v1..v2: removed unused "re

Re: [PATCHv2] usb: gadget: f_tcm: ignore return value of queue_work

2015-12-10 Thread Andrzej Pietrasiewicz
Hi W dniu 10.12.2015 o 17:51, Felipe Balbi pisze: Hi, Andrzej Pietrasiewicz <andrze...@samsung.com> writes: queue_work() has never returned anything less than zero. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> I don't have f_tcm.c anywhere. Where did you base

[PATCH] usb: gadget: f_tcm: ignore return value of queue_work

2015-12-09 Thread Andrzej Pietrasiewicz
queue_work() has never returned anything less than zero. Reported-by: Dan Carpenter <dan.carpen...@oracle.com> Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- This patch depends on the series adding configfs support to tcm usb gadget: http://www.spinics.net/lists/

Re: usb: gadget: tcm: factor out f_tcm

2015-12-08 Thread Andrzej Pietrasiewicz
Hi Dan, W dniu 08.12.2015 o 14:15, Dan Carpenter pisze: Hello Andrzej Pietrasiewicz, The patch b4b91143ec45: "usb: gadget: tcm: factor out f_tcm" from Oct 27, 2015, leads to the following static checker warning: drivers/usb/gadget/function/f_tcm.c:1149 usbg_subm

Re: [PATCHv3 00/14] Equivalent of tcm_usb_gadget with configfs

2015-12-01 Thread Andrzej Pietrasiewicz
Hi Nicholas, W dniu 29.11.2015 o 07:16, Nicholas A. Bellinger pisze: Hi Andrzej & Co, On Mon, 2015-11-23 at 09:22 +0100, Andrzej Pietrasiewicz wrote: W dniu 15.11.2015 o 00:27, Nicholas A. Bellinger pisze: Hi Andrzej & Co, Ok, I've added both series into target-pending/queue

[PATCHv4 08/11] usb: gadget: f_tcm: remove compatibility layer

2015-12-01 Thread Andrzej Pietrasiewicz
There are no old function interface users left. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/function/f_tcm.c | 87 +++-- 1 file changed, 6 insertions(+), 81 deletions(-) diff --git a/drivers/usb/gadget/function/f_tc

[PATCHv4 09/11] usb: gadget: f_tcm: remove redundant singleton

2015-12-01 Thread Andrzej Pietrasiewicz
The only instance is guaranteed with TPG_INSTANCES defined to 1. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/function/f_tcm.c | 9 - drivers/usb/gadget/function/tcm.h | 2 -- 2 files changed, 11 deletions(-) diff --git a/drivers/usb/

[PATCHv4 07/11] usb: gadget: tcm: convert to use new function registration interface

2015-12-01 Thread Andrzej Pietrasiewicz
Convert the only user of old tcm function interface so that the old interface can be removed. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/legacy/Kconfig | 1 + drivers/usb/gadget/legacy/tcm_usb_gadget.c | 62 +--

[PATCHv4 05/11] usb: gadget: tcm: factor out f_tcm

2015-12-01 Thread Andrzej Pietrasiewicz
Prepare for converting tcm to new function registration interface. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/function/f_tcm.c| 2151 drivers/usb/gadget/function/tcm.h | 132 ++ drivers/usb/gadget/

[PATCHv4 00/11] Equivalent of tcm_usb_gadget with configfs

2015-12-01 Thread Andrzej Pietrasiewicz
= The most basic testing device: run the script above host: see the gadget enumerated *** BLURB HERE *** Andrzej Pietrasiewicz (11): usb: gadget: tcm: split string definitions into function and device usb: gadget: tcm: follow naming conventions usb: gadget: tcm: use strtobool for a bool

[PATCHv4 06/11] usb: gadget: f_tcm: convert to new function interface with backward compatibility

2015-12-01 Thread Andrzej Pietrasiewicz
of preprocessor conditional directives. After all users are converted, the old interface can be removed. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/Kconfig | 3 + drivers/usb/gadget/function/Makefile | 2 + drivers/usb/gadget/function/f

[PATCHv4 10/11] usb: gadget: f_tcm: use usb_gstrings_attach

2015-12-01 Thread Andrzej Pietrasiewicz
Do not directly use file static strings definitions in instances of f_tcm. Instead use usb_gstrings_attach. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/function/f_tcm.c | 18 +++--- 1 file changed, 7 insertions(+), 11 deletions(-) diff

[PATCHv4 03/11] usb: gadget: tcm: use strtobool for a boolean value

2015-12-01 Thread Andrzej Pietrasiewicz
Simplify the function. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/legacy/tcm_usb_gadget.c | 10 -- 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/drivers/usb/gadget/legacy/tcm_usb_gadget.c b/drivers/usb/gadget/

Re: [PATCHv4 00/11] Equivalent of tcm_usb_gadget with configfs

2015-12-01 Thread Andrzej Pietrasiewicz
v3..v4: - rebased onto current Nicholas' tree (b1c06ebadd277421c3f59569708ed356eb5dded5, tcm_usb_gadget: Fix enabled attribute failure) The commit hash-id onto which the series is rebased should be: 1cc92aed7192caa8987bba0f88226f57e9b4ed73 Sorry for confusion, AP -- To unsubscribe from

[PATCHv4 01/11] usb: gadget: tcm: split string definitions into function and device

2015-12-01 Thread Andrzej Pietrasiewicz
Prepare for factoring out f_tcm from a legacy gadget. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/legacy/tcm_usb_gadget.c | 25 + drivers/usb/gadget/legacy/tcm_usb_gadget.h | 3 +-- 2 files changed, 22 insertions(+), 6 del

[PATCHv4 04/11] usb: gadget: tcm: simplify attribute store function

2015-12-01 Thread Andrzej Pietrasiewicz
Simplify function code. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/legacy/tcm_usb_gadget.c | 22 +++--- 1 file changed, 7 insertions(+), 15 deletions(-) diff --git a/drivers/usb/gadget/legacy/tcm_usb_gadget.c b/drivers/usb/gadget/

[PATCHv4 11/11] usb: gadget: f_tcm: add configfs support

2015-12-01 Thread Andrzej Pietrasiewicz
Allow using the tcm function as a component of a gadget composed with ConfigFS. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- Documentation/ABI/testing/configfs-usb-gadget-tcm | 6 ++ drivers/usb/gadget/Kconfig| 14 + drivers/usb/gadget/fu

Re: [PATCHv3 00/14] Equivalent of tcm_usb_gadget with configfs

2015-11-23 Thread Andrzej Pietrasiewicz
W dniu 15.11.2015 o 00:27, Nicholas A. Bellinger pisze: Hi Andrzej & Co, Ok, I've added both series into target-pending/queue-next so kbuild can give it a first pass. We'll need to get Jlbec's ACK on the configfs parts, and Sebastian's ACK on this series ahead of getting them into next

Re: [PATCH v4 1/4] fs: configfs: Drop unused parameter from configfs_undepend_item()

2015-11-13 Thread Andrzej Pietrasiewicz
Hello, W dniu 26.10.2015 o 17:43, Krzysztof Opasiak pisze: subsys parameter is never used by configfs_undepend_item() so there is no point in passing it to this function. Signed-off-by: Krzysztof Opasiak --- Changes since v3: - fix build break in ocfs2 Any comments

[PATCHv3 08/14] usb: gadget: tcm: factor out f_tcm

2015-10-27 Thread Andrzej Pietrasiewicz
Prepare for converting tcm to new function registration interface. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/function/f_tcm.c| 2168 drivers/usb/gadget/function/tcm.h | 132 ++ drivers/usb/gadget/

[PATCHv3 03/14] tcm_usb_gadget: Fix enabled attribute failure

2015-10-27 Thread Andrzej Pietrasiewicz
From: Nicholas Bellinger <n...@linux-iscsi.org> Fix up tcm_usbg_tpg_store_enable() return value to propagate usbg_attach() failure up to user-space if no HDC is found. Reported-by: Andrzej Pietrasiewicz <andrze...@samsung.com> Cc: Andrzej Pietrasiewicz <andrze...@samsung.com

[PATCHv3 14/14] usb: gadget: f_tcm: add configfs support

2015-10-27 Thread Andrzej Pietrasiewicz
Allow using the tcm function as a component of a gadget composed with ConfigFS. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- Documentation/ABI/testing/configfs-usb-gadget-tcm | 6 ++ drivers/usb/gadget/Kconfig| 14 + drivers/usb/gadget/fu

[PATCHv3 09/14] usb: gadget: f_tcm: convert to new function interface with backward compatibility

2015-10-27 Thread Andrzej Pietrasiewicz
of preprocessor conditional directives. After all users are converted, the old interface can be removed. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/Kconfig | 3 + drivers/usb/gadget/function/Makefile | 2 + drivers/usb/gadget/function/f

[PATCHv3 04/14] usb: gadget: tcm: split string definitions into function and device

2015-10-27 Thread Andrzej Pietrasiewicz
Prepare for factoring out f_tcm from a legacy gadget. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/legacy/tcm_usb_gadget.c | 25 + drivers/usb/gadget/legacy/tcm_usb_gadget.h | 3 +-- 2 files changed, 22 insertions(+), 6 del

[PATCHv3 12/14] usb: gadget: f_tcm: remove redundant singleton

2015-10-27 Thread Andrzej Pietrasiewicz
The only instance is guaranteed with TPG_INSTANCES defined to 1. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/function/f_tcm.c | 9 - drivers/usb/gadget/function/tcm.h | 2 -- 2 files changed, 11 deletions(-) diff --git a/drivers/usb/

[PATCHv3 11/14] usb: gadget: f_tcm: remove compatibility layer

2015-10-27 Thread Andrzej Pietrasiewicz
There are no old function interface users left. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/function/f_tcm.c | 87 +++-- 1 file changed, 6 insertions(+), 81 deletions(-) diff --git a/drivers/usb/gadget/function/f_tc

[PATCHv3 10/14] usb: gadget: tcm: convert to use new function registration interface

2015-10-27 Thread Andrzej Pietrasiewicz
Convert the only user of old tcm function interface so that the old interface can be removed. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/legacy/Kconfig | 1 + drivers/usb/gadget/legacy/tcm_usb_gadget.c | 62 +--

[PATCHv3 13/14] usb: gadget: f_tcm: use usb_gstrings_attach

2015-10-27 Thread Andrzej Pietrasiewicz
Do not directly use file static strings definitions in instances of f_tcm. Instead use usb_gstrings_attach. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/function/f_tcm.c | 18 +++--- 1 file changed, 7 insertions(+), 11 deletions(-) diff

[PATCHv3 01/14] tcm_usb_gadget: Don't strip off nexus WWPN prefix

2015-10-27 Thread Andrzej Pietrasiewicz
OT, so it will not effect host side code. Reported-by: Andrzej Pietrasiewicz <andrze...@samsung.com> Cc: Andrzej Pietrasiewicz <andrze...@samsung.com> Cc: Sebastian Andrzej Siewior <bige...@linutronix.de> Signed-off-by: Nicholas Bellinger <n...@linux-iscsi.org>

[PATCHv3 06/14] usb: gadget: tcm: use strtobool for a boolean value

2015-10-27 Thread Andrzej Pietrasiewicz
Simplify the function. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/legacy/tcm_usb_gadget.c | 10 -- 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/drivers/usb/gadget/legacy/tcm_usb_gadget.c b/drivers/usb/gadget/

[PATCHv3 07/14] usb: gadget: tcm: simplify attribute store function

2015-10-27 Thread Andrzej Pietrasiewicz
Simplify function code. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/legacy/tcm_usb_gadget.c | 22 +++--- 1 file changed, 7 insertions(+), 15 deletions(-) diff --git a/drivers/usb/gadget/legacy/tcm_usb_gadget.c b/drivers/usb/gadget/

[PATCHv3 05/14] usb: gadget: tcm: follow naming conventions

2015-10-27 Thread Andrzej Pietrasiewicz
Prepare for splitting tcm_usb_gadget into legacy gadget proper and f_tcm. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/legacy/tcm_usb_gadget.c | 28 ++-- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/drive

[PATCHv3 00/14] Equivalent of tcm_usb_gadget with configfs

2015-10-27 Thread Andrzej Pietrasiewicz
RODUCT_ID > idProduct # echo 1240.dwc3 > UDC TESTING THE FUNCTION The most basic testing device: run the script above host: see the gadget enumerated Andrzej Pietrasiewicz (11): usb: gadget: tcm: split string definitions into function and device usb: gadget: tcm: f

[PATCHv3 02/14] tcm_usb_gadget: Fix nexus leak

2015-10-27 Thread Andrzej Pietrasiewicz
From: Nicholas Bellinger <n...@linux-iscsi.org> This patch adds the missing tcm_usbg_drop_nexus() to properly release tcm_usbg_nexus memory during typical ->fabric_drop_tpg() callback shutdown. Reported-by: Andrzej Pietrasiewicz <andrze...@samsung.com> Cc: Andrzej Pietra

Re: [PATCHv2 01/15] fs: configfs: Add unlocked version of configfs_depend_item()

2015-10-27 Thread Andrzej Pietrasiewicz
W dniu 26.10.2015 o 16:35, Krzysztof Opasiak pisze: Hi Christoph, I have just updated this patch but it turned out that to applying your remarks I should split this into a few commits. That's why I decided to send it as a separate series[1]. @Andrzej Could you please rebase your series

Re: [PATCHv2 01/15] fs: configfs: Add unlocked version of configfs_depend_item()

2015-10-23 Thread Andrzej Pietrasiewicz
W dniu 22.10.2015 o 17:22, Christoph Hellwig pisze: Hi Andrzej, please find a way to share code between the two depend function. And also drop the duplicate undepend version and just stop passing the unused subsystem argument. Not only do we not keep unused argument in Linux in general, but

[PATCHv2 10/15] usb: gadget: f_tcm: convert to new function interface with backward compatibility

2015-10-22 Thread Andrzej Pietrasiewicz
of preprocessor conditional directives. After all users are converted, the old interface can be removed. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/Kconfig | 3 + drivers/usb/gadget/function/Makefile | 2 + drivers/usb/gadget/function/f

[PATCHv2 14/15] usb: gadget: f_tcm: use usb_gstrings_attach

2015-10-22 Thread Andrzej Pietrasiewicz
Do not directly use file static strings definitions in instances of f_tcm. Instead use usb_gstrings_attach. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/function/f_tcm.c | 18 +++--- 1 file changed, 7 insertions(+), 11 deletions(-) diff

[PATCHv2 15/15] usb: gadget: f_tcm: add configfs support

2015-10-22 Thread Andrzej Pietrasiewicz
Allow using the tcm function as a component of a gadget composed with ConfigFS. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> [adapt to new prototype of configfs_(un)depend_item())] Signed-off-by: Krzysztof Opasiak <k.opas...@samsung.com> --- Documentation/ABI/testing/

[PATCHv2 00/15] Equivalent of tcm_usb_gadget with configfs

2015-10-22 Thread Andrzej Pietrasiewicz
_gadget/tcm # mkdir configs/c.1 # ln -s functions/tcm.0 configs/c.1 # echo $VENDOR_ID > idVendor # echo $PRODUCT_ID > idProduct # echo 1240.dwc3 > UDC TESTING THE FUNCTION The most basic testing device: run the script above host: see the gadget enumerated Andrz

[PATCHv2 06/15] usb: gadget: tcm: follow naming conventions

2015-10-22 Thread Andrzej Pietrasiewicz
Prepare for splitting tcm_usb_gadget into legacy gadget proper and f_tcm. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/legacy/tcm_usb_gadget.c | 28 ++-- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/drive

[PATCHv2 07/15] usb: gadget: tcm: use strtobool for a boolean value

2015-10-22 Thread Andrzej Pietrasiewicz
Simplify the function. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/legacy/tcm_usb_gadget.c | 10 -- 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/drivers/usb/gadget/legacy/tcm_usb_gadget.c b/drivers/usb/gadget/

[PATCHv2 08/15] usb: gadget: tcm: simplify attribute store function

2015-10-22 Thread Andrzej Pietrasiewicz
Simplify function code. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/legacy/tcm_usb_gadget.c | 22 +++--- 1 file changed, 7 insertions(+), 15 deletions(-) diff --git a/drivers/usb/gadget/legacy/tcm_usb_gadget.c b/drivers/usb/gadget/

[PATCHv2 01/15] fs: configfs: Add unlocked version of configfs_depend_item()

2015-10-22 Thread Andrzej Pietrasiewicz
state but we have to lock root of configfs to avoid unregistration of target's subsystem. As it is other than caller's subsystem, there may be nothing what protects us against unregistration of that subsystem. Signed-off-by: Krzysztof Opasiak <k.opas...@samsung.com> Signed-off

[PATCHv2 13/15] usb: gadget: f_tcm: remove redundant singleton

2015-10-22 Thread Andrzej Pietrasiewicz
The only instance is guaranteed with TPG_INSTANCES defined to 1. Signed-off-by: Andrzej Pietrasiewicz <andrze...@samsung.com> --- drivers/usb/gadget/function/f_tcm.c | 9 - drivers/usb/gadget/function/tcm.h | 2 -- 2 files changed, 11 deletions(-) diff --git a/drivers/usb/

  1   2   3   4   5   6   7   8   9   10   >