Re: staging: Add MA USB Host driver

2020-01-21 Thread Dan Carpenter
On Mon, Jan 20, 2020 at 09:30:43AM +, Vladimir Stankovic wrote:
> +int mausb_enqueue_event_from_user(uint8_t madev_addr, uint32_t all_events)
> +{
> + unsigned long flags;
> + uint16_t num_of_completed,
> +  num_of_events;
> + struct mausb_device *dev;
> +
> + spin_lock_irqsave(&mss.lock, flags);
> + dev = mausb_get_dev_from_addr_unsafe(madev_addr);
> +
> + if (!dev) {
> + spin_unlock_irqrestore(&mss.lock, flags);
> + return 0;
> + }
> +
> + spin_lock_irqsave(&dev->num_of_user_events_lock, flags);
> + num_of_completed = (uint16_t)all_events +
> +(uint16_t)dev->num_of_user_events;
> + num_of_events= (all_events >> (8 * sizeof(num_of_events))) +
> + (dev->num_of_user_events >> (8 * sizeof(num_of_events)));
> + dev->num_of_user_events  = num_of_completed;
> + dev->num_of_user_events |= (uint32_t)num_of_events <<
> + (8 * sizeof(num_of_events));

I might be missing something.  Why can't we just declare two struct
members instead of doing these bit shifts to fit two values into
dev->num_of_user_events?

> + spin_unlock_irqrestore(&dev->num_of_user_events_lock, flags);
> + queue_work(dev->workq, &dev->work);
> + spin_unlock_irqrestore(&mss.lock, flags);
> +
> + return 0;
> +}

regards,
dan carpenter
___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel


Re: [PATCH v3] media: allegro: add missed checks in allegro_open()

2020-01-21 Thread Michael Tretter
On Mon, 13 Jan 2020 13:59:51 +0800, Chuhong Yuan wrote:
> allegro_open() misses checks for v4l2_m2m_ctx_init() and results of
> v4l2_ctrl_new* calls.
> Add checks and error handlers to fix the problems.
> 
> Signed-off-by: Chuhong Yuan 
> ---
> Changes in v3:
>   - Make code cleaner.
>   - Add a check for handler->error.
> 
>  .../staging/media/allegro-dvt/allegro-core.c  | 24 +++
>  1 file changed, 20 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/staging/media/allegro-dvt/allegro-core.c 
> b/drivers/staging/media/allegro-dvt/allegro-core.c
> index 6f0cd0784786..e86001e42963 100644
> --- a/drivers/staging/media/allegro-dvt/allegro-core.c
> +++ b/drivers/staging/media/allegro-dvt/allegro-core.c
> @@ -2270,15 +2270,12 @@ static int allegro_open(struct file *file)
>   struct allegro_channel *channel = NULL;
>   struct v4l2_ctrl_handler *handler;
>   u64 mask;
> + int ret;
>  
>   channel = kzalloc(sizeof(*channel), GFP_KERNEL);
>   if (!channel)
>   return -ENOMEM;
>  
> - v4l2_fh_init(&channel->fh, vdev);
> - file->private_data = &channel->fh;
> - v4l2_fh_add(&channel->fh);
> -
>   init_completion(&channel->completion);
>  
>   channel->dev = dev;
> @@ -2328,6 +2325,11 @@ static int allegro_open(struct file *file)
>   V4L2_CID_MIN_BUFFERS_FOR_OUTPUT,
>   1, 32,
>   1, 1);
> + if (handler->error != 0) {
> + ret = handler->error;
> + goto error;
> + }
> +
>   channel->fh.ctrl_handler = handler;
>  
>   channel->mcu_channel_id = -1;
> @@ -2341,7 +2343,21 @@ static int allegro_open(struct file *file)
>   channel->fh.m2m_ctx = v4l2_m2m_ctx_init(dev->m2m_dev, channel,
>   allegro_queue_init);
>  
> + if (IS_ERR(channel->fh.m2m_ctx)) {
> + ret = PTR_ERR(channel->fh.m2m_ctx);
> + goto error;
> + }
> +
> + v4l2_fh_init(&channel->fh, vdev);

This call sets channel->fh.ctrl_handler to vdev->ctrl_handler, which
has previously been overriden by the driver to handler. Therefore, this
patch breaks all controls. I think we should initialize channel->fh
before setting any fields of this struct.

Michael

> + file->private_data = &channel->fh;
> + v4l2_fh_add(&channel->fh);
> +
>   return 0;
> +
> +error:
> + v4l2_ctrl_handler_free(handler);
> + kfree(channel);
> + return ret;
>  }
>  
>  static int allegro_release(struct file *file)
___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel


[PATCH] staging: axis-fifo: replace spinlock with mutex

2020-01-21 Thread Quentin Deslandes
Following the device's documentation guidance, reading a packet from the
device or writing a packet to it must be atomic. Previously, only
reading device's vacancy (before writing on it) or occupancy (before
reading from it) was locked. Hence, effectively reading the packet or
writing the packet wasn't locked at all. However, reading a packet (and
writing one, to a lesser extent) requires to read 3 different registers
in a specific order, without missing one or else we should reset the
device.

This patch fixes the device's locking mechanism on the FIFO character
device. As the device was using copy_from_user() and copy_to_user(), we
need to replace spinlocks with mutexes.

Signed-off-by: Quentin Deslandes 
---
 drivers/staging/axis-fifo/axis-fifo.c | 160 --
 1 file changed, 101 insertions(+), 59 deletions(-)

diff --git a/drivers/staging/axis-fifo/axis-fifo.c 
b/drivers/staging/axis-fifo/axis-fifo.c
index 39e6c59df1e9..5801067e7c1b 100644
--- a/drivers/staging/axis-fifo/axis-fifo.c
+++ b/drivers/staging/axis-fifo/axis-fifo.c
@@ -16,7 +16,7 @@
 
 #include 
 #include 
-#include 
+#include 
 #include 
 #include 
 #include 
@@ -133,9 +133,9 @@ struct axis_fifo {
int has_tx_fifo; /* whether the IP has the tx fifo enabled */
 
wait_queue_head_t read_queue; /* wait queue for asynchronos read */
-   spinlock_t read_queue_lock; /* lock for reading waitqueue */
+   struct mutex read_lock; /* lock for reading */
wait_queue_head_t write_queue; /* wait queue for asynchronos write */
-   spinlock_t write_queue_lock; /* lock for writing waitqueue */
+   struct mutex write_lock; /* lock for writing */
unsigned int write_flags; /* write file flags */
unsigned int read_flags; /* read file flags */
 
@@ -336,7 +336,21 @@ static void reset_ip_core(struct axis_fifo *fifo)
iowrite32(XLLF_INT_ALL_MASK, fifo->base_addr + XLLF_ISR_OFFSET);
 }
 
-/* reads a single packet from the fifo as dictated by the tlast signal */
+/**
+ * axis_fifo_write() - Read a packet from AXIS-FIFO character device.
+ * @f Open file.
+ * @buf User space buffer to read to.
+ * @len User space buffer length.
+ * @off Buffer offset.
+ *
+ * As defined by the device's documentation, we need to check the device's
+ * occupancy before reading the length register and then the data. All these
+ * operations must be executed atomically, in order and one after the other
+ * without missing any.
+ *
+ * Returns the number of bytes read from the device or negative error code
+ * on failure.
+ */
 static ssize_t axis_fifo_read(struct file *f, char __user *buf,
  size_t len, loff_t *off)
 {
@@ -350,36 +364,37 @@ static ssize_t axis_fifo_read(struct file *f, char __user 
*buf,
u32 tmp_buf[READ_BUF_SIZE];
 
if (fifo->read_flags & O_NONBLOCK) {
-   /* opened in non-blocking mode
-* return if there are no packets available
+   /*
+* Device opened in non-blocking mode. Try to lock it and then
+* check if any packet is available.
 */
-   if (!ioread32(fifo->base_addr + XLLF_RDFO_OFFSET))
+   if (!mutex_trylock(&fifo->read_lock))
return -EAGAIN;
+
+   if (!ioread32(fifo->base_addr + XLLF_RDFO_OFFSET)) {
+   ret = -EAGAIN;
+   goto end_unlock;
+   }
} else {
/* opened in blocking mode
 * wait for a packet available interrupt (or timeout)
 * if nothing is currently available
 */
-   spin_lock_irq(&fifo->read_queue_lock);
-   ret = wait_event_interruptible_lock_irq_timeout
-   (fifo->read_queue,
-ioread32(fifo->base_addr + XLLF_RDFO_OFFSET),
-fifo->read_queue_lock,
-(read_timeout >= 0) ? msecs_to_jiffies(read_timeout) :
+   mutex_lock(&fifo->read_lock);
+   ret = wait_event_interruptible_timeout(fifo->read_queue,
+   ioread32(fifo->base_addr + XLLF_RDFO_OFFSET),
+   (read_timeout >= 0) ? msecs_to_jiffies(read_timeout) :
MAX_SCHEDULE_TIMEOUT);
-   spin_unlock_irq(&fifo->read_queue_lock);
 
-   if (ret == 0) {
-   /* timeout occurred */
-   dev_dbg(fifo->dt_device, "read timeout");
-   return -EAGAIN;
-   } else if (ret == -ERESTARTSYS) {
-   /* signal received */
-   return -ERESTARTSYS;
-   } else if (ret < 0) {
-   dev_err(fifo->dt_device, 
"wait_event_interruptible_timeout() error in read (ret=%i)\n",
-   ret);
-   return ret;
+   if (ret <= 0

Re: [PATCH v3] media: allegro: add missed checks in allegro_open()

2020-01-21 Thread Chuhong Yuan
On Tue, Jan 21, 2020 at 4:23 PM Michael Tretter
 wrote:
>
> On Mon, 13 Jan 2020 13:59:51 +0800, Chuhong Yuan wrote:
> > allegro_open() misses checks for v4l2_m2m_ctx_init() and results of
> > v4l2_ctrl_new* calls.
> > Add checks and error handlers to fix the problems.
> >
> > Signed-off-by: Chuhong Yuan 
> > ---
> > Changes in v3:
> >   - Make code cleaner.
> >   - Add a check for handler->error.
> >
> >  .../staging/media/allegro-dvt/allegro-core.c  | 24 +++
> >  1 file changed, 20 insertions(+), 4 deletions(-)
> >
> > diff --git a/drivers/staging/media/allegro-dvt/allegro-core.c 
> > b/drivers/staging/media/allegro-dvt/allegro-core.c
> > index 6f0cd0784786..e86001e42963 100644
> > --- a/drivers/staging/media/allegro-dvt/allegro-core.c
> > +++ b/drivers/staging/media/allegro-dvt/allegro-core.c
> > @@ -2270,15 +2270,12 @@ static int allegro_open(struct file *file)
> >   struct allegro_channel *channel = NULL;
> >   struct v4l2_ctrl_handler *handler;
> >   u64 mask;
> > + int ret;
> >
> >   channel = kzalloc(sizeof(*channel), GFP_KERNEL);
> >   if (!channel)
> >   return -ENOMEM;
> >
> > - v4l2_fh_init(&channel->fh, vdev);
> > - file->private_data = &channel->fh;
> > - v4l2_fh_add(&channel->fh);
> > -
> >   init_completion(&channel->completion);
> >
> >   channel->dev = dev;
> > @@ -2328,6 +2325,11 @@ static int allegro_open(struct file *file)
> >   V4L2_CID_MIN_BUFFERS_FOR_OUTPUT,
> >   1, 32,
> >   1, 1);
> > + if (handler->error != 0) {
> > + ret = handler->error;
> > + goto error;
> > + }
> > +
> >   channel->fh.ctrl_handler = handler;
> >
> >   channel->mcu_channel_id = -1;
> > @@ -2341,7 +2343,21 @@ static int allegro_open(struct file *file)
> >   channel->fh.m2m_ctx = v4l2_m2m_ctx_init(dev->m2m_dev, channel,
> >   allegro_queue_init);
> >
> > + if (IS_ERR(channel->fh.m2m_ctx)) {
> > + ret = PTR_ERR(channel->fh.m2m_ctx);
> > + goto error;
> > + }
> > +
> > + v4l2_fh_init(&channel->fh, vdev);
>
> This call sets channel->fh.ctrl_handler to vdev->ctrl_handler, which
> has previously been overriden by the driver to handler. Therefore, this
> patch breaks all controls. I think we should initialize channel->fh
> before setting any fields of this struct.
>

I'm not very clear about this issue.
In my second version, Hans replied that init could be moved before return 0.
I have sent this mail to him.

> Michael
>
> > + file->private_data = &channel->fh;
> > + v4l2_fh_add(&channel->fh);
> > +
> >   return 0;
> > +
> > +error:
> > + v4l2_ctrl_handler_free(handler);
> > + kfree(channel);
> > + return ret;
> >  }
> >
> >  static int allegro_release(struct file *file)
___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel


[PATCH] staging: mt7621-pinctrl: Align to fix warnings of line over 80 characters

2020-01-21 Thread Sandesh Kenjana Ashok
Issue found by checkpatch.

Signed-off-by: Sandesh Kenjana Ashok 
---
 drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 11 ++-
 1 file changed, 6 insertions(+), 5 deletions(-)

diff --git a/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c 
b/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c
index d0f06790d38f..df5da5fce630 100644
--- a/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c
+++ b/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c
@@ -159,7 +159,8 @@ static int rt2880_pmx_group_enable(struct pinctrl_dev 
*pctrldev,
 }
 
 static int rt2880_pmx_group_gpio_request_enable(struct pinctrl_dev *pctrldev,
-   struct pinctrl_gpio_range 
*range,
+   struct pinctrl_gpio_range
+   *range,
unsigned int pin)
 {
struct rt2880_priv *p = pinctrl_dev_get_drvdata(pctrldev);
@@ -218,10 +219,10 @@ static int rt2880_pinmux_index(struct rt2880_priv *p)
p->func_count++;
 
/* allocate our function and group mapping index buffers */
-   f = p->func = devm_kcalloc(p->dev,
-  p->func_count,
-  sizeof(struct rt2880_pmx_func),
-  GFP_KERNEL);
+   f = p->func;
+   p->func =  devm_kcalloc(p->dev, p->func_count,
+   sizeof(struct rt2880_pmx_func), GFP_KERNEL);
+
gpio_func.groups = devm_kcalloc(p->dev, p->group_count, sizeof(int),
GFP_KERNEL);
if (!f || !gpio_func.groups)
-- 
2.17.1

___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel


Re: [PATCH v3] media: allegro: add missed checks in allegro_open()

2020-01-21 Thread Michael Tretter
On Tue, 21 Jan 2020 19:59:46 +0800, Chuhong Yuan wrote:
> On Tue, Jan 21, 2020 at 4:23 PM Michael Tretter
>  wrote:
> >
> > On Mon, 13 Jan 2020 13:59:51 +0800, Chuhong Yuan wrote:  
> > > allegro_open() misses checks for v4l2_m2m_ctx_init() and results of
> > > v4l2_ctrl_new* calls.
> > > Add checks and error handlers to fix the problems.
> > >
> > > Signed-off-by: Chuhong Yuan 
> > > ---
> > > Changes in v3:
> > >   - Make code cleaner.
> > >   - Add a check for handler->error.
> > >
> > >  .../staging/media/allegro-dvt/allegro-core.c  | 24 +++
> > >  1 file changed, 20 insertions(+), 4 deletions(-)
> > >
> > > diff --git a/drivers/staging/media/allegro-dvt/allegro-core.c 
> > > b/drivers/staging/media/allegro-dvt/allegro-core.c
> > > index 6f0cd0784786..e86001e42963 100644
> > > --- a/drivers/staging/media/allegro-dvt/allegro-core.c
> > > +++ b/drivers/staging/media/allegro-dvt/allegro-core.c
> > > @@ -2270,15 +2270,12 @@ static int allegro_open(struct file *file)
> > >   struct allegro_channel *channel = NULL;
> > >   struct v4l2_ctrl_handler *handler;
> > >   u64 mask;
> > > + int ret;
> > >
> > >   channel = kzalloc(sizeof(*channel), GFP_KERNEL);
> > >   if (!channel)
> > >   return -ENOMEM;
> > >
> > > - v4l2_fh_init(&channel->fh, vdev);
> > > - file->private_data = &channel->fh;
> > > - v4l2_fh_add(&channel->fh);
> > > -
> > >   init_completion(&channel->completion);
> > >
> > >   channel->dev = dev;
> > > @@ -2328,6 +2325,11 @@ static int allegro_open(struct file *file)
> > >   V4L2_CID_MIN_BUFFERS_FOR_OUTPUT,
> > >   1, 32,
> > >   1, 1);
> > > + if (handler->error != 0) {
> > > + ret = handler->error;
> > > + goto error;
> > > + }
> > > +
> > >   channel->fh.ctrl_handler = handler;
> > >
> > >   channel->mcu_channel_id = -1;
> > > @@ -2341,7 +2343,21 @@ static int allegro_open(struct file *file)
> > >   channel->fh.m2m_ctx = v4l2_m2m_ctx_init(dev->m2m_dev, channel,
> > >   allegro_queue_init);
> > >
> > > + if (IS_ERR(channel->fh.m2m_ctx)) {
> > > + ret = PTR_ERR(channel->fh.m2m_ctx);
> > > + goto error;
> > > + }
> > > +
> > > + v4l2_fh_init(&channel->fh, vdev);  
> >
> > This call sets channel->fh.ctrl_handler to vdev->ctrl_handler, which
> > has previously been overriden by the driver to handler. Therefore, this
> > patch breaks all controls. I think we should initialize channel->fh
> > before setting any fields of this struct.
> >  
> 
> I'm not very clear about this issue.
> In my second version, Hans replied that init could be moved before return 0.
> I have sent this mail to him.

This driver uses its own v4l2_ctrl_handler, which is initialized in this
function (see the "handler" variable). After the initialization, the
handler is added to the fh as

channel->fh.ctrl_handler = handler;

to override the ctrl_handler of the fh.

However, the v4l2_fh_init() function re-initializes the ctrl_handler of
the fh

/* Inherit from video_device. May be overridden by the driver. */
fh->ctrl_handler = vdev->ctrl_handler;

which reverts the ctrl_handler override by the driver.

Therefore, the ctrl_handler must be overridden after the call to
v4l2_fh_init().

Michael

> 
> > Michael
> >  
> > > + file->private_data = &channel->fh;
> > > + v4l2_fh_add(&channel->fh);
> > > +
> > >   return 0;
> > > +
> > > +error:
> > > + v4l2_ctrl_handler_free(handler);
> > > + kfree(channel);
> > > + return ret;
> > >  }
> > >
> > >  static int allegro_release(struct file *file)  
> 
___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel


Re: [PATCH] staging: mt7621-pinctrl: Align to fix warnings of line over 80 characters

2020-01-21 Thread Greg Kroah-Hartman
On Tue, Jan 21, 2020 at 02:47:05PM +0100, Sandesh Kenjana Ashok wrote:
> Issue found by checkpatch.
> 
> Signed-off-by: Sandesh Kenjana Ashok 
> ---
>  drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 11 ++-
>  1 file changed, 6 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c 
> b/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c
> index d0f06790d38f..df5da5fce630 100644
> --- a/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c
> +++ b/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c
> @@ -159,7 +159,8 @@ static int rt2880_pmx_group_enable(struct pinctrl_dev 
> *pctrldev,
>  }
>  
>  static int rt2880_pmx_group_gpio_request_enable(struct pinctrl_dev *pctrldev,
> - struct pinctrl_gpio_range 
> *range,
> + struct pinctrl_gpio_range
> + *range,

Ick, that looks worse now, right?  checkpatch is a guideline, not a
hard-and-fast rule here.

>   unsigned int pin)
>  {
>   struct rt2880_priv *p = pinctrl_dev_get_drvdata(pctrldev);
> @@ -218,10 +219,10 @@ static int rt2880_pinmux_index(struct rt2880_priv *p)
>   p->func_count++;
>  
>   /* allocate our function and group mapping index buffers */
> - f = p->func = devm_kcalloc(p->dev,
> -p->func_count,
> -sizeof(struct rt2880_pmx_func),
> -GFP_KERNEL);
> + f = p->func;
> + p->func =  devm_kcalloc(p->dev, p->func_count,
> + sizeof(struct rt2880_pmx_func), GFP_KERNEL);
> +

You broke the code here :(

Please learn a bit more about how C works before attempting to work on
kernel code.

thanks,

greg k-h
___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel


[PATCH] staging: mt7621-pinctrl: Align code by cleanup long lines

2020-01-21 Thread Sandesh Kenjana Ashok
Cleanup lines over 80 characters in pinctrl-rt2880.c.
Issue found by checkpatch.pl

Signed-off-by: Sandesh Kenjana Ashok 
---
 drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c 
b/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c
index d0f06790d38f..254d4eb88f5f 100644
--- a/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c
+++ b/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c
@@ -159,8 +159,8 @@ static int rt2880_pmx_group_enable(struct pinctrl_dev 
*pctrldev,
 }
 
 static int rt2880_pmx_group_gpio_request_enable(struct pinctrl_dev *pctrldev,
-   struct pinctrl_gpio_range 
*range,
-   unsigned int pin)
+   struct pinctrl_gpio_range *range,
+   unsigned int pin)
 {
struct rt2880_priv *p = pinctrl_dev_get_drvdata(pctrldev);
 
-- 
2.17.1

___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel


Re: staging: Add MA USB Host driver

2020-01-21 Thread gre...@linuxfoundation.org
On Mon, Jan 20, 2020 at 09:30:43AM +, Vladimir Stankovic wrote:
> MA-USB Host driver provides USB connectivity over an available
> network, allowing host device to access remote USB devices attached
> to one or more MA USB devices (accessible via network).
> 
> This driver has been developed to enable the host to communicate
> with DislayLink products supporting MA USB protocol (MA USB device,
> in terms of MA USB Specification).
> 
> MA-USB protocol used by MA-USB Host driver has been implemented in
> accordance with MA USB Specification Release 1.0b.
> 
> This driver depends on the functions provided by DisplayLink's
> user-space driver.
> 
> Signed-off-by: Vladimir Stankovic 

Why is this being submitted to staging and not to the "real" part of the
kernel?  You need a TODO file that lists what is left to be done to the
driver to get it merged to the proper place in the kernel tree.  Can you
please resubmit with that file added to the patch?

thanks,

greg k-h
___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel


Re: [External] Re: staging: Add MA USB Host driver

2020-01-21 Thread Vladimir Stankovic
Hi Greg,

Our intention was to follow Linux kernel development process and add our
driver to staging first.
Will resubmit patch with TODO added.

Regards,
Vladimir

On 22.1.20. 08:03, gre...@linuxfoundation.org wrote:
> On Mon, Jan 20, 2020 at 09:30:43AM +, Vladimir Stankovic wrote:
>> MA-USB Host driver provides USB connectivity over an available
>> network, allowing host device to access remote USB devices attached
>> to one or more MA USB devices (accessible via network).
>>
>> This driver has been developed to enable the host to communicate
>> with DislayLink products supporting MA USB protocol (MA USB device,
>> in terms of MA USB Specification).
>>
>> MA-USB protocol used by MA-USB Host driver has been implemented in
>> accordance with MA USB Specification Release 1.0b.
>>
>> This driver depends on the functions provided by DisplayLink's
>> user-space driver.
>>
>> Signed-off-by: Vladimir Stankovic 
> 
> Why is this being submitted to staging and not to the "real" part of the
> kernel?  You need a TODO file that lists what is left to be done to the
> driver to get it merged to the proper place in the kernel tree.  Can you
> please resubmit with that file added to the patch?
> 
> thanks,
> 
> greg k-h
> 

___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel


Re: [External] Re: staging: Add MA USB Host driver

2020-01-21 Thread gre...@linuxfoundation.org
On Wed, Jan 22, 2020 at 07:40:59AM +, Vladimir Stankovic wrote:
> Hi Greg,
> 
> Our intention was to follow Linux kernel development process and add our
> driver to staging first.

That's not the "normal" development process at all, where did you read
that?

staging is only for code that needs lots of work, and almost always
merging a driver through staging takes _more_ work from the submitter
than it does to submit it through the "normal" subsystem.

So if you want to do more work, hey, by all means, send it here :)

thanks,

greg k-h
___
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel