Re: [PATCH -next] input/touchscreen: fix sur40.c build errors

2015-04-15 Thread Florian Echtler
Hello Randy, On 15.04.2015 17:54, Randy Dunlap wrote: > --- > drivers/input/touchscreen/Kconfig |1 + > 1 file changed, 1 insertion(+) > > --- linux-next-20150415.orig/drivers/input/touchscreen/Kconfig > +++ linux-next-20150415/drivers/input/touchscreen/Kconfig > @@ -981,6 +981,7 @@ config T

[PATCH] sur40: fix occasional hard freeze due to buffer queue underrun

2015-03-31 Thread Florian Echtler
n the spinlock is taken and sur40_poll attempts to fetch the next buffer from buf_list, the list is in fact empty. This patch needs to be applied on top of the queued one adding V4L2 support to the sur40 driver. Signed-off-by: Florian Echtler --- drivers/input/touchscreen/sur40.c | 5 + 1

Re: input_polldev interval (was Re: [sur40] Debugging a race condition)?

2015-03-27 Thread Florian Echtler
Hello Antonio, On 26.03.2015 22:10, Antonio Ospite wrote: > On Wed, 25 Mar 2015 15:10:44 +0100 > Florian Echtler wrote: >> >> Thanks - any other suggestions how to debug such a complete freeze? I >> have the following options enabled in my kernel config: >> &g

Re: input_polldev interval (was Re: [sur40] Debugging a race condition)?

2015-03-25 Thread Florian Echtler
Hello Dmitry, On 25.03.2015 14:23, Dmitry Torokhov wrote: > On March 24, 2015 11:52:54 PM PDT, Florian Echtler > wrote: >> Currently, I'm setting the interval for input_polldev to 10 ms. >> However, with video data being retrieved at the same time, it's quite >&

input_polldev interval (was Re: [sur40] Debugging a race condition)?

2015-03-24 Thread Florian Echtler
than that. Could this ultimately be the reason? What happens if a new poll() call is scheduled before the previous one completes? Best, Florian On March 23, 2015 4:47:19 PM CET, Florian Echtler wrote: >Additional note: this happens almost never with the original code using >dma-contig, which

Re: [sur40] Debugging a race condition?

2015-03-23 Thread Florian Echtler
e that can help somebody in narrowing down the reason of the problem? Best, Florian On 23.03.2015 12:57, Florian Echtler wrote: > Hello everyone, > > now that I'm using the newly merged sur40 video driver in a development > environment, I've noticed that a custom V4L2 appl

[sur40] Debugging a race condition?

2015-03-23 Thread Florian Echtler
Hello everyone, now that I'm using the newly merged sur40 video driver in a development environment, I've noticed that a custom V4L2 application we've been using in our lab will sometimes trigger a hard lockup of the machine (_nothing_ works anymore, no VT switching, no network, not even Magic Sys

[PATCH v5] add raw video stream support for Samsung SUR40

2015-03-16 Thread Florian Echtler
This patch adds raw video support for the Samsung SUR40 using vbuf2-dma-sg. All tests from v4l2-compliance pass. Support for VB2_USERPTR is currently disabled due to unexpected interference with dma-sg buffer sizes. Signed-off-by: Florian Echtler --- drivers/input/touchscreen/Kconfig | 2

Re: [PATCH v3][RFC] add raw video stream support for Samsung SUR40

2015-03-16 Thread Florian Echtler
Hello Hans, On 15.03.2015 17:26, Hans Verkuil wrote: > On 03/12/2015 08:37 PM, Florian Echtler wrote: >> On 09.03.2015 15:02, Hans Verkuil wrote: >>> On 03/09/2015 02:45 PM, Florian Echtler wrote: >>>> On 09.03.2015 11:09, Hans Verkuil wrote: >>>&

[PATCH v4] add raw video stream support for Samsung SUR40

2015-03-16 Thread Florian Echtler
This patch adds raw video support for the Samsung SUR40 using vbuf2-dma-sg. All tests from v4l2-compliance pass. Support for VB2_USERPTR is currently disabled due to unexpected interference with dma-sg buffer sizes. Signed-off-by: Florian Echtler --- drivers/input/touchscreen/Kconfig | 2

Re: [PATCH v3][RFC] add raw video stream support for Samsung SUR40

2015-03-12 Thread Florian Echtler
Hello Hans, On 09.03.2015 15:02, Hans Verkuil wrote: > On 03/09/2015 02:45 PM, Florian Echtler wrote: >> On 09.03.2015 11:09, Hans Verkuil wrote: >>> The error almost certainly comes from usb_submit_urb(). That function does >>> some >>> checks on the sgl: >

Re: [PATCH v3][RFC] add raw video stream support for Samsung SUR40

2015-03-09 Thread Florian Echtler
On 09.03.2015 11:09, Hans Verkuil wrote: > Hi Florian, > > OK, the cause of this failure is this message: > > Mar 9 10:39:08 sur40 kernel: [ 1093.200960] sur40 2-1:1.0: error in > usb_sg_wait > > So you need to print the error message here (sgr.status) so that I can see > what > it is. I've a

Re: [PATCH v3][RFC] add raw video stream support for Samsung SUR40

2015-03-06 Thread Florian Echtler
On 21.02.2015 11:22, Hans Verkuil wrote: > On 02/20/2015 10:46 PM, Florian Echtler wrote: >> On 16.02.2015 12:40, Hans Verkuil wrote: >>> On 02/11/2015 12:52 PM, Florian Echtler wrote: >>> I prefer to dig into this a little bit more, as I don't really understan

Re: [PATCH] HID: Add driver for acer keybard with broken rdesc

2015-02-27 Thread Florian Echtler
Just as a quick side note, Simon's "hack" compiled as a standalone module fixes the issue for me on stock kernel 3.16.0 - keyboard works perfectly now. So device 06CB:2991 has exactly the same broken descriptor and should probably included in any future solution. Many thanks to everyone involved!

Re: Inactive keyboard on Acer Aspire Switch 11

2015-02-27 Thread Florian Echtler
Hello Benjamin, On 27.02.2015 01:46, Benjamin Tissoires wrote: > On Thu, Feb 26, 2015 at 6:18 PM, Florian Echtler wrote: >> The device in question has two endpoints: >> >> T: Bus=02 Lev=02 Prnt=04 Port=02 Cnt=01 Dev#= 7 Spd=12 MxCh= 0 >> D: Ver= 2.00 Cls=00(&g

Inactive keyboard on Acer Aspire Switch 11

2015-02-26 Thread Florian Echtler
Hello everyone, I've recently bought an Acer Aspire Switch 11 convertible tablet/notebook hybrid device. Ubuntu 14.04.2 with kernel 3.16 runs almost perfectly, with one notable exception: on the keyboard dock, only the touchpad works, not the keyboard itself. I've done a bit of digging in the logs

Re: [PATCH v3][RFC] add raw video stream support for Samsung SUR40

2015-02-20 Thread Florian Echtler
On 16.02.2015 12:40, Hans Verkuil wrote: > On 02/11/2015 12:52 PM, Florian Echtler wrote: >> does anyone have any suggestions why USERPTR still fails with dma-sg? >> >> Could I just disable the corresponding capability for the moment so that >> the patch could perhaps

Re: [PATCH v3][RFC] add raw video stream support for Samsung SUR40

2015-02-11 Thread Florian Echtler
Hello again, does anyone have any suggestions why USERPTR still fails with dma-sg? Could I just disable the corresponding capability for the moment so that the patch could perhaps be merged, and investigate this separately? Best, Florian On 04.02.2015 16:30, Florian Echtler wrote: > This pa

[PATCH v3][RFC] add raw video stream support for Samsung SUR40

2015-02-04 Thread Florian Echtler
This patch adds raw video support for the Samsung SUR40, now finally using videobuf2-dma-sg and the usb_sg_init/_wait helper functions. Further comments regarding buffer handling are invited, as v4l2-compliance -s still fails the USERPTR test. Signed-off-by: Florian Echtler --- drivers/input

Re: [PATCH] add raw video support for Samsung SUR40 touchscreen

2015-02-04 Thread Florian Echtler
Hello everyone, On 04.02.2015 12:39, Hans Verkuil wrote: > On 02/04/15 12:34, Laurent Pinchart wrote: >> On Wednesday 04 February 2015 11:56:58 Florian Echtler wrote: >>> That's what I assumed, however, I'm running into the same problem as >>> with dma-sg

[PATCH v2][RFC] add raw video support for Samsung SUR40 touchscreen

2015-02-04 Thread Florian Echtler
t, specify --expbuf-device Total: 45, Succeeded: 44, Failed: 1, Warnings: 0 Signed-off-by: Florian Echtler --- drivers/input/touchscreen/Kconfig | 2 + drivers/input/touchscreen/sur40.c | 422 -- 2 files changed, 412 insertions(+), 12 deletions(-) diff --git a/dri

Re: [PATCH] add raw video support for Samsung SUR40 touchscreen

2015-02-04 Thread Florian Echtler
On 04.02.2015 11:22, Hans Verkuil wrote: > On 02/04/15 11:08, Florian Echtler wrote: >> On 04.02.2015 09:08, Hans Verkuil wrote: >>> You can also make a version with vmalloc and I'll merge that, and then >>> you can look more into the DMA issues. That way the dri

Re: [PATCH] add raw video support for Samsung SUR40 touchscreen

2015-02-04 Thread Florian Echtler
Hello Hans, On 04.02.2015 09:08, Hans Verkuil wrote: > I remain very skeptical about the use of dma-contig (or dma-sg for that > matter). Have you tried using vmalloc and check if the USB core isn't > automatically using DMA transfers for that? > > Basically I would like to see proof that vmalloc

Re: [PATCH] add raw video support for Samsung SUR40 touchscreen

2015-02-03 Thread Florian Echtler
Sorry to bring this up again, but would it be acceptable to simply use dma-contig after all? Since the GFP_DMA flag is gone, this shouldn't be too big of an issue IMHO, and I was kind of hoping the patch could still be part of 3.20. Best, Florian On 29.01.2015 22:35, Florian Echtler wrote:

Re: [PATCH] add raw video support for Samsung SUR40 touchscreen

2015-01-29 Thread Florian Echtler
Hello again, On 21.01.2015 14:29, Hans Verkuil wrote: > On 01/21/15 14:28, Florian Echtler wrote: >> On 20.01.2015 14:06, Laurent Pinchart wrote: >>> That depends on the platform and whether it can DMA to vmalloc'ed memory >>> :-) >>> To be totally saf

Re: [PATCH] add raw video support for Samsung SUR40 touchscreen

2015-01-21 Thread Florian Echtler
Hello everyone, On 20.01.2015 14:06, Laurent Pinchart wrote: > On Tuesday 20 January 2015 14:03:00 Hans Verkuil wrote: >> On 01/20/15 13:59, Laurent Pinchart wrote: >>> On Tuesday 20 January 2015 10:30:07 Hans Verkuil wrote: I've CC-ed Laurent, I think he knows a lot more about this than I do

Re: [PATCH] add raw video support for Samsung SUR40 touchscreen

2015-01-20 Thread Florian Echtler
Hello Hans, On 19.01.2015 11:38, Hans Verkuil wrote: > Sorry for the delay. No problem, thanks for your feedback. >> Note: I'm intentionally using dma-contig instead of vmalloc, as the USB >> core apparently _will_ try to use DMA for larger bulk transfers. > As far as I can tell from looking thr

[PATCH] add raw video support for Samsung SUR40 touchscreen

2015-01-07 Thread Florian Echtler
://floe.butterbrot.org/external/results.txt for details). Note: I'm intentionally using dma-contig instead of vmalloc, as the USB core apparently _will_ try to use DMA for larger bulk transfers. Signed-off-by: Florian Echtler --- drivers/input/touchscreen/sur40.c

Re: [RFC] [Patch] implement video driver for sur40

2015-01-06 Thread Florian Echtler
On 06.01.2015 11:23, Hans Verkuil wrote: > On 01/06/2015 11:17 AM, Florian Echtler wrote: >>> You're not filling in the 'field' field of struct v4l2_buffer when >>> returning a >>> frame. It should most likely be FIELD_NONE in your case. >>>&g

Re: [RFC] [Patch] implement video driver for sur40

2015-01-06 Thread Florian Echtler
On 06.01.2015 10:36, Hans Verkuil wrote: > On 01/06/2015 10:29 AM, Florian Echtler wrote: >> There's only one failing test left, which is this one: >> >> Streaming ioctls: >> test read/write: OK >> fail: v4l2-test-buffers.cpp(284): g_fie

Re: [RFC] [Patch] implement video driver for sur40

2015-01-06 Thread Florian Echtler
On Fri, 19 Dec 2014, Hans Verkuil wrote: drivers/media remains under heavy development, so for video capture drivers like yours you should always patch against either the mainline linux tree or (preferred) the media_tree.git repo (git://linuxtv.org/media_tree.git, master branch). As per your sugg

Re: [RFC] [Patch] implement video driver for sur40

2014-12-19 Thread Florian Echtler
On 19.12.2014 15:36, Hans Verkuil wrote: > On 12/19/2014 03:30 PM, Florian Echtler wrote: >> Ran the most recent version from git master, got a total of 6 fails, 4 >> of which are probably easy fixes: >> >>> fail: v4l2-compliance.cpp(306): missing bus_info prefix (&#x

Re: [RFC] [Patch] implement video driver for sur40

2014-12-19 Thread Florian Echtler
On 18.12.2014 15:11, Hans Verkuil wrote: > Run as 'v4l2-compliance -s' (-s starts streaming tests as well and it > assumes you have a valid input signal). > Mail if you have any questions about the v4l2-compliance output. The failure > messages expect you to look at the v4l2-compliance source code

[RFC] [Patch] implement video driver for sur40

2014-12-18 Thread Florian Echtler
Hello everyone, as promised, I've finally implemented the missing raw video feature for the SUR40 touchscreen. Since this is a bit of a weird hybrid device (multitouch input as well as video), I'm hoping for comments from both communities (linux-input and linux-media). I'm also attaching the full

[sur40] videobuf2 and/or DMA?

2014-12-07 Thread Florian Echtler
Hello everyone, I'm preparing to finally add support for the raw sensor video stream to my driver for the SUR40 touchscreen. However, after an extensive amount of Googling, I'm still not clear on the relationship between DMA transfers, the USB core and the videobuf2 framework. Specifically, I'd l

Re: [git pull] Input updates for 3.13-rc0 (2nd)

2013-11-23 Thread Florian Echtler
elog: > - > > Dan Carpenter (1): > Input: hp_sdc_rtc - unlock on error in hp_sdc_rtc_read_i8042timer() > > Dmitry Torokhov (1): > Input: atmel-wm97xx - fix compile error > > Florian Echtler (1): > Input: add sur40 driver for Samsung SUR40 (aka MS S

Re: [PATCH v3] add sur40 driver for Samsung SUR40 (aka MS Surface 2.0/Pixelsense)

2013-11-18 Thread Florian Echtler
Hello Henrik, thanks for the info, sorry for me being such a nuisance :-) I'll submit the patch to the Ubuntu kernel team once it's merged into Dmitry's tree, would be great to see this in the next LTS version. Best regards, Florian On 16.11.2013 19:08, Henrik Rydberg wrote: > Hi Florian, > >>

Re: [PATCH v3] add sur40 driver for Samsung SUR40 (aka MS Surface 2.0/Pixelsense)

2013-11-16 Thread Florian Echtler
Looks like the sur40 driver didn't make it into the 3.13 pull request, anything still missing/broken? I was hoping this might still make it into Ubuntu 14.04... BR, Florian Florian Echtler wrote: On 11.11.2013 11:27, Henrik Rydberg wrote: >> Also, does the patch below mess up o

Re: [PATCH v3] add sur40 driver for Samsung SUR40 (aka MS Surface 2.0/Pixelsense)

2013-11-12 Thread Florian Echtler
it's fine? > No need to resubmit, a confirmation will do nicely. Thanks! > Henrik I've tested Dmitry's additional patch, confirmed to work. Just for the record: Tested-by: Florian Echtler BR, Florian -- SENT FROM MY DEC VT50 TERMINAL signature.asc Description: OpenPGP digital signature

Re: [PATCH v3] add sur40 driver for Samsung SUR40 (aka MS Surface 2.0/Pixelsense)

2013-11-11 Thread Florian Echtler
Hello Dmitry, On 11.11.2013 08:31, Dmitry Torokhov wrote: > Hi Florian, > > On Wed, Nov 06, 2013 at 03:26:51PM +0100, Florian Echtler wrote: >> + >> +/* max value unknown, but major/minor axis >> + * can never be larger than screen */ >> +

[PATCH v3] add sur40 driver for Samsung SUR40 (aka MS Surface 2.0/Pixelsense)

2013-11-06 Thread Florian Echtler
From: "Florian Echtler" This patch adds support for the built-in multitouch sensor in the Samsung SUR40 touchscreen device, also known as Microsoft Surface 2.0 or Microsoft Pixelsense. Support for raw video output from the sensor as well as the accelerometer will be added in a l

Re: [PATCH v2] add sur40 driver for Samsung SUR40 (aka MS Surface 2.0/Pixelsense)

2013-10-21 Thread Florian Echtler
Hello Dmitry, thanks for your quick feedback, a few questions below: On 21.10.2013 18:20, Dmitry Torokhov wrote: > On Sun, Oct 20, 2013 at 06:49:11PM +0200, Florian Echtler wrote: >> +/* read 512 bytes from endpoint 0x86 -> get header + blobs */ >> +struct sur40_header { >

[PATCH v2] add sur40 driver for Samsung SUR40 (aka MS Surface 2.0/Pixelsense)

2013-10-20 Thread Florian Echtler
be added in a later patch. Signed-off-by: Florian Echtler --- drivers/input/touchscreen/Kconfig | 10 + drivers/input/touchscreen/Makefile |1 + drivers/input/touchscreen/sur40.c | 446 3 files changed, 457 insertions(+) create mode 100644 drivers/inp

Re: [PATCH] add sur40 driver for Samsung SUR40 (aka MS Surface 2.0/Pixelsense)

2013-10-11 Thread Florian Echtler
On 02.10.2013 15:59, David Herrmann wrote: >>> Or maybe even replace it by "u32 angle;". That should always be safe. >>> Once you make use of this field, you can reconsider whether it's worth >>> doing FP in the kernel. But as long as it's unused, I'd vote for >>> avoiding "float" entirely. >> >> I

Re: [PATCH] add sur40 driver for Samsung SUR40 (aka MS Surface 2.0/Pixelsense)

2013-10-02 Thread Florian Echtler
On 18.09.2013 21:38, Henrik Rydberg wrote: > Hi Florian, > Thanks for the driver, this is excellent work. Please find some nit-picks > inline. Hello Henrik, thanks for your feedback and sorry for the long silence - some final questions before the next iteration are below: >> +/* read 512 bytes

Re: [PATCH] add sur40 driver for Samsung SUR40 (aka MS Surface 2.0/Pixelsense)

2013-09-18 Thread Florian Echtler
Best regards, Florian On 11.09.2013 23:26, Florian Echtler wrote: > This patch adds support for the built-in multitouch sensor in the Samsung > SUR40 touchscreen device, also known as Microsoft Surface 2.0 or Microsoft > Pixelsense. Support for raw video output from the sensor as well as the &

[PATCH] add sur40 driver for Samsung SUR40 (aka MS Surface 2.0/Pixelsense)

2013-09-11 Thread Florian Echtler
From: "Florian Echtler" This patch adds support for the built-in multitouch sensor in the Samsung SUR40 touchscreen device, also known as Microsoft Surface 2.0 or Microsoft Pixelsense. Support for raw video output from the sensor as well as the accelerometer will be added in a l

Re: [RFC] surface-input

2013-09-09 Thread Florian Echtler
On 06.09.2013 15:25, Benjamin Tissoires wrote: > Some generic comments: > - please always inline the code in the message, it is *much* easier to review > and comment it > - please directly use a patch format: if the code is good, Dmitry can take it > directly through his tree > - add the followin

[RFC] surface-input

2013-09-05 Thread Florian Echtler
Hello everyone, as mentioned earlier, I'm currently writing a multitouch input driver for the Pixelsense (formerly Surface 2.0). It's now at a point where I'd consider it mostly done, but a) I have very limited experience with kernel drivers and b) there are some additional questions I have, so I'

Behaviour of input-polldev?

2013-09-03 Thread Florian Echtler
Hello everyone, I'm in the process of writing an input driver for the Microsoft Pixelsense (formerly Surface 2.0). The device only has bulk endpoints and consequently needs to be polled regularly. My beta driver uses input-polldev for this, and it appears to work nicely, however, I couldn't find o

Re: [PATCH] HID: wiimote: fix weight conversion error for values > 17kg

2012-09-18 Thread Florian Echtler
Thanks Jiri, and sorry for the noise :-) On 18.09.2012 11:38, Jiri Kosina wrote: On Mon, 17 Sep 2012, Florian Echtler wrote: Signed-Off-By: Florian Echtler --- drivers/hid/hid-wiimote-ext.c |3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/hid/hid-wiimote

[PATCH] HID: wiimote: fix weight conversion error for values > 17kg

2012-09-17 Thread Florian Echtler
Signed-Off-By: Florian Echtler --- drivers/hid/hid-wiimote-ext.c |3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/hid/hid-wiimote-ext.c b/drivers/hid/hid-wiimote-ext.c index fc98cc9..bc85bf2 100644 --- a/drivers/hid/hid-wiimote-ext.c +++ b/drivers/hid/hid-wiimote

Re: [PATCH 2/2] HID: wiimote: Parse calibration data of balance boards

2012-09-17 Thread Florian Echtler
Darn, I just realized there may be an error here: On 17.09.2012 12:31, David Herrmann wrote: drivers/hid/hid-wiimote-ext.c | 39 ++- 1 file changed, 38 insertions(+), 1 deletion(-) + /* apply calibration data */ + for (i = 0; i < 4; i++) { +

Re: [PATCH 1/2] HID: wiimote: Add Nintendo Balance-Board support

2012-09-17 Thread Florian Echtler
Tested-by: Florian Echtler On 17.09.2012 12:31, David Herrmann wrote: The Nintendo Balance-Board is a controller which behaves exactly like the Wii Remote but reports all its data through a special extension device. Hence, we can simply add the Balance-Board as extension device and we get full

Re: [PATCH 2/2] HID: wiimote: Parse calibration data of balance boards

2012-09-17 Thread Florian Echtler
Signed-off-by: Florian Echtler On 17.09.2012 12:31, David Herrmann wrote: From: Florian Echtler The raw pressure-data that is reported by balance-boards is pretty useless unless calibration data is applied. Therefore, we read the full calibration data on extension initialization and apply it