linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] staging: comedi: addi_apci_1564: move apci1564_di_insn_bits() to addi_apci_1564.c
@ 2014-05-22  0:40 Chase Southwood
  2014-05-22  0:41 ` [PATCH 2/2] staging: comedi: addi_apci_1564: move apci1564_do_insn_bits() " Chase Southwood
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Chase Southwood @ 2014-05-22  0:40 UTC (permalink / raw)
  To: gregkh; +Cc: abbotti, hsweeten, devel, linux-kernel, Chase Southwood

This function is already compliant with the comedi API and is behaving as
comedi core expects.  This patch moves it out of
addi-data/hwdrv_apci1564.c and into the driver proper since no further
work needs to be done on it.

Cc: Ian Abbott <abbotti@mev.co.uk>
Cc: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Chase Southwood <chase.southwood@gmail.com>
---
 drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c | 12 ------------
 drivers/staging/comedi/drivers/addi_apci_1564.c           | 12 ++++++++++++
 2 files changed, 12 insertions(+), 12 deletions(-)

diff --git a/drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c b/drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c
index b3c3f60..533d156 100644
--- a/drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c
+++ b/drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c
@@ -129,18 +129,6 @@ static int apci1564_di_config(struct comedi_device *dev,
 	return insn->n;
 }
 
-static int apci1564_di_insn_bits(struct comedi_device *dev,
-				 struct comedi_subdevice *s,
-				 struct comedi_insn *insn,
-				 unsigned int *data)
-{
-	struct addi_private *devpriv = dev->private;
-
-	data[1] = inl(devpriv->i_IobaseAmcc + APCI1564_DI_REG);
-
-	return insn->n;
-}
-
 /*
  * Configures The Digital Output Subdevice.
  *
diff --git a/drivers/staging/comedi/drivers/addi_apci_1564.c b/drivers/staging/comedi/drivers/addi_apci_1564.c
index cbccbb6..fe477cc5 100644
--- a/drivers/staging/comedi/drivers/addi_apci_1564.c
+++ b/drivers/staging/comedi/drivers/addi_apci_1564.c
@@ -14,6 +14,18 @@ static irqreturn_t v_ADDI_Interrupt(int irq, void *d)
 	return IRQ_RETVAL(1);
 }
 
+static int apci1564_di_insn_bits(struct comedi_device *dev,
+				 struct comedi_subdevice *s,
+				 struct comedi_insn *insn,
+				 unsigned int *data)
+{
+	struct addi_private *devpriv = dev->private;
+
+	data[1] = inl(devpriv->i_IobaseAmcc + APCI1564_DI_REG);
+
+	return insn->n;
+}
+
 static int apci1564_reset(struct comedi_device *dev)
 {
 	struct addi_private *devpriv = dev->private;
-- 
1.9.0


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 2/2] staging: comedi: addi_apci_1564: move apci1564_do_insn_bits() to addi_apci_1564.c
  2014-05-22  0:40 [PATCH 1/2] staging: comedi: addi_apci_1564: move apci1564_di_insn_bits() to addi_apci_1564.c Chase Southwood
@ 2014-05-22  0:41 ` Chase Southwood
  2014-05-22  9:25   ` Ian Abbott
  2014-05-22 16:33   ` Hartley Sweeten
  2014-05-22  9:24 ` [PATCH 1/2] staging: comedi: addi_apci_1564: move apci1564_di_insn_bits() " Ian Abbott
  2014-05-22 16:31 ` Hartley Sweeten
  2 siblings, 2 replies; 6+ messages in thread
From: Chase Southwood @ 2014-05-22  0:41 UTC (permalink / raw)
  To: gregkh; +Cc: abbotti, hsweeten, devel, linux-kernel, Chase Southwood

This function is already compliant with the comedi API and is behaving as
comedi core expects.  This patch moves it out of
addi-data/hwdrv_apci1564.c and into the driver proper since no further
work needs to be done on it.

Cc: Ian Abbott <abbotti@mev.co.uk>
Cc: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Chase Southwood <chase.southwood@gmail.com>
---
Just a couple patches in this set, but with these out of the way, the
next patchset can focus entirely on getting the change-of-state interrupt
functionality working.  Made sense to just finish up with DI/DO and start
COS interrupts separately.

 .../staging/comedi/drivers/addi-data/hwdrv_apci1564.c   | 17 -----------------
 drivers/staging/comedi/drivers/addi_apci_1564.c         | 17 +++++++++++++++++
 2 files changed, 17 insertions(+), 17 deletions(-)

diff --git a/drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c b/drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c
index 533d156..0ba5385 100644
--- a/drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c
+++ b/drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c
@@ -170,23 +170,6 @@ static int apci1564_do_config(struct comedi_device *dev,
 	return insn->n;
 }
 
-static int apci1564_do_insn_bits(struct comedi_device *dev,
-				 struct comedi_subdevice *s,
-				 struct comedi_insn *insn,
-				 unsigned int *data)
-{
-	struct addi_private *devpriv = dev->private;
-
-	s->state = inl(devpriv->i_IobaseAmcc + APCI1564_DO_REG);
-
-	if (comedi_dio_update_state(s, data))
-		outl(s->state, devpriv->i_IobaseAmcc + APCI1564_DO_REG);
-
-	data[1] = s->state;
-
-	return insn->n;
-}
-
 /*
  * Configures The Timer, Counter or Watchdog
  *
diff --git a/drivers/staging/comedi/drivers/addi_apci_1564.c b/drivers/staging/comedi/drivers/addi_apci_1564.c
index fe477cc5..13d9962 100644
--- a/drivers/staging/comedi/drivers/addi_apci_1564.c
+++ b/drivers/staging/comedi/drivers/addi_apci_1564.c
@@ -26,6 +26,23 @@ static int apci1564_di_insn_bits(struct comedi_device *dev,
 	return insn->n;
 }
 
+static int apci1564_do_insn_bits(struct comedi_device *dev,
+				 struct comedi_subdevice *s,
+				 struct comedi_insn *insn,
+				 unsigned int *data)
+{
+	struct addi_private *devpriv = dev->private;
+
+	s->state = inl(devpriv->i_IobaseAmcc + APCI1564_DO_REG);
+
+	if (comedi_dio_update_state(s, data))
+		outl(s->state, devpriv->i_IobaseAmcc + APCI1564_DO_REG);
+
+	data[1] = s->state;
+
+	return insn->n;
+}
+
 static int apci1564_reset(struct comedi_device *dev)
 {
 	struct addi_private *devpriv = dev->private;
-- 
1.9.0


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH 1/2] staging: comedi: addi_apci_1564: move apci1564_di_insn_bits() to addi_apci_1564.c
  2014-05-22  0:40 [PATCH 1/2] staging: comedi: addi_apci_1564: move apci1564_di_insn_bits() to addi_apci_1564.c Chase Southwood
  2014-05-22  0:41 ` [PATCH 2/2] staging: comedi: addi_apci_1564: move apci1564_do_insn_bits() " Chase Southwood
@ 2014-05-22  9:24 ` Ian Abbott
  2014-05-22 16:31 ` Hartley Sweeten
  2 siblings, 0 replies; 6+ messages in thread
From: Ian Abbott @ 2014-05-22  9:24 UTC (permalink / raw)
  To: Chase Southwood, gregkh; +Cc: hsweeten, devel, linux-kernel

On 2014-05-22 01:40, Chase Southwood wrote:
> This function is already compliant with the comedi API and is behaving as
> comedi core expects.  This patch moves it out of
> addi-data/hwdrv_apci1564.c and into the driver proper since no further
> work needs to be done on it.
>
> Cc: Ian Abbott <abbotti@mev.co.uk>
> Cc: H Hartley Sweeten <hsweeten@visionengravers.com>
> Signed-off-by: Chase Southwood <chase.southwood@gmail.com>
> ---
>   drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c | 12 ------------
>   drivers/staging/comedi/drivers/addi_apci_1564.c           | 12 ++++++++++++
>   2 files changed, 12 insertions(+), 12 deletions(-)

Looks fine, but depends on two series of your patches (4 + 2 patches) 
being applied to staging-next before this one.

Reviewed-by: Ian Abbott <abbotti@mev.co.uk>

-- 
-=( Ian Abbott @ MEV Ltd.    E-mail: <abbotti@mev.co.uk>        )=-
-=( Tel: +44 (0)161 477 1898   FAX: +44 (0)161 718 3587         )=-

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 2/2] staging: comedi: addi_apci_1564: move apci1564_do_insn_bits() to addi_apci_1564.c
  2014-05-22  0:41 ` [PATCH 2/2] staging: comedi: addi_apci_1564: move apci1564_do_insn_bits() " Chase Southwood
@ 2014-05-22  9:25   ` Ian Abbott
  2014-05-22 16:33   ` Hartley Sweeten
  1 sibling, 0 replies; 6+ messages in thread
From: Ian Abbott @ 2014-05-22  9:25 UTC (permalink / raw)
  To: Chase Southwood, gregkh; +Cc: hsweeten, devel, linux-kernel

On 2014-05-22 01:41, Chase Southwood wrote:
> This function is already compliant with the comedi API and is behaving as
> comedi core expects.  This patch moves it out of
> addi-data/hwdrv_apci1564.c and into the driver proper since no further
> work needs to be done on it.
>
> Cc: Ian Abbott <abbotti@mev.co.uk>
> Cc: H Hartley Sweeten <hsweeten@visionengravers.com>
> Signed-off-by: Chase Southwood <chase.southwood@gmail.com>
> ---
> Just a couple patches in this set, but with these out of the way, the
> next patchset can focus entirely on getting the change-of-state interrupt
> functionality working.  Made sense to just finish up with DI/DO and start
> COS interrupts separately.
>
>   .../staging/comedi/drivers/addi-data/hwdrv_apci1564.c   | 17 -----------------
>   drivers/staging/comedi/drivers/addi_apci_1564.c         | 17 +++++++++++++++++
>   2 files changed, 17 insertions(+), 17 deletions(-)

Reviewed-by: Ian Abbott <abbotti@mev.co.uk>

-- 
-=( Ian Abbott @ MEV Ltd.    E-mail: <abbotti@mev.co.uk>        )=-
-=( Tel: +44 (0)161 477 1898   FAX: +44 (0)161 718 3587         )=-

^ permalink raw reply	[flat|nested] 6+ messages in thread

* RE: [PATCH 1/2] staging: comedi: addi_apci_1564: move apci1564_di_insn_bits() to addi_apci_1564.c
  2014-05-22  0:40 [PATCH 1/2] staging: comedi: addi_apci_1564: move apci1564_di_insn_bits() to addi_apci_1564.c Chase Southwood
  2014-05-22  0:41 ` [PATCH 2/2] staging: comedi: addi_apci_1564: move apci1564_do_insn_bits() " Chase Southwood
  2014-05-22  9:24 ` [PATCH 1/2] staging: comedi: addi_apci_1564: move apci1564_di_insn_bits() " Ian Abbott
@ 2014-05-22 16:31 ` Hartley Sweeten
  2 siblings, 0 replies; 6+ messages in thread
From: Hartley Sweeten @ 2014-05-22 16:31 UTC (permalink / raw)
  To: Chase Southwood, gregkh; +Cc: abbotti, devel, linux-kernel

On Wednesday, May 21, 2014 5:40 PM, Chase Southwood wrote:
>
> This function is already compliant with the comedi API and is behaving as
> comedi core expects.  This patch moves it out of
> addi-data/hwdrv_apci1564.c and into the driver proper since no further
> work needs to be done on it.
>
> Cc: Ian Abbott <abbotti@mev.co.uk>
> Cc: H Hartley Sweeten <hsweeten@visionengravers.com>
> Signed-off-by: Chase Southwood <chase.southwood@gmail.com>

Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com>


^ permalink raw reply	[flat|nested] 6+ messages in thread

* RE: [PATCH 2/2] staging: comedi: addi_apci_1564: move apci1564_do_insn_bits() to addi_apci_1564.c
  2014-05-22  0:41 ` [PATCH 2/2] staging: comedi: addi_apci_1564: move apci1564_do_insn_bits() " Chase Southwood
  2014-05-22  9:25   ` Ian Abbott
@ 2014-05-22 16:33   ` Hartley Sweeten
  1 sibling, 0 replies; 6+ messages in thread
From: Hartley Sweeten @ 2014-05-22 16:33 UTC (permalink / raw)
  To: Chase Southwood, gregkh; +Cc: abbotti, devel, linux-kernel

On Wednesday, May 21, 2014 5:41 PM, Chase Southwood wrote:
>
> This function is already compliant with the comedi API and is behaving as
> comedi core expects.  This patch moves it out of
> addi-data/hwdrv_apci1564.c and into the driver proper since no further
> work needs to be done on it.
>
> Cc: Ian Abbott <abbotti@mev.co.uk>
> Cc: H Hartley Sweeten <hsweeten@visionengravers.com>
> Signed-off-by: Chase Southwood <chase.southwood@gmail.com>

Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com>


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2014-05-22 16:33 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-05-22  0:40 [PATCH 1/2] staging: comedi: addi_apci_1564: move apci1564_di_insn_bits() to addi_apci_1564.c Chase Southwood
2014-05-22  0:41 ` [PATCH 2/2] staging: comedi: addi_apci_1564: move apci1564_do_insn_bits() " Chase Southwood
2014-05-22  9:25   ` Ian Abbott
2014-05-22 16:33   ` Hartley Sweeten
2014-05-22  9:24 ` [PATCH 1/2] staging: comedi: addi_apci_1564: move apci1564_di_insn_bits() " Ian Abbott
2014-05-22 16:31 ` Hartley Sweeten

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).