Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754600AbbDUMSl (ORCPT ); Tue, 21 Apr 2015 08:18:41 -0400 Received: from smtp89.iad3a.emailsrvr.com ([173.203.187.89]:33267 "EHLO smtp89.iad3a.emailsrvr.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753959AbbDUMSh (ORCPT ); Tue, 21 Apr 2015 08:18:37 -0400 X-Sender-Id: abbotti@mev.co.uk From: Ian Abbott To: Cc: Greg Kroah-Hartman , Ian Abbott , H Hartley Sweeten , Subject: [PATCH 2/2] staging: comedi: move COMEDI_SRF_... macros to "comedi_fops.c" Date: Tue, 21 Apr 2015 13:18:11 +0100 Message-Id: <1429618691-7157-3-git-send-email-abbotti@mev.co.uk> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1429618691-7157-1-git-send-email-abbotti@mev.co.uk> References: <1429618691-7157-1-git-send-email-abbotti@mev.co.uk> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2819 Lines: 74 The `COMEDI_SRF_...` macros define flag combinations in the `runflags` member of `struct comedi_subdevice`. They are only used directly in "comedi_fops.c", so move them to there. Signed-off-by: Ian Abbott --- drivers/staging/comedi/comedi_fops.c | 17 +++++++++++++++++ drivers/staging/comedi/comedidev.h | 17 ----------------- 2 files changed, 17 insertions(+), 17 deletions(-) diff --git a/drivers/staging/comedi/comedi_fops.c b/drivers/staging/comedi/comedi_fops.c index fc339c5..6f269cc 100644 --- a/drivers/staging/comedi/comedi_fops.c +++ b/drivers/staging/comedi/comedi_fops.c @@ -44,6 +44,23 @@ #include "comedi_internal.h" /** + * comedi_subdevice "runflags" + * @COMEDI_SRF_RT: DEPRECATED: command is running real-time + * @COMEDI_SRF_ERROR: indicates an COMEDI_CB_ERROR event has occurred + * since the last command was started + * @COMEDI_SRF_RUNNING: command is running + * @COMEDI_SRF_FREE_SPRIV: free s->private on detach + * + * @COMEDI_SRF_BUSY_MASK: runflags that indicate the subdevice is "busy" + */ +#define COMEDI_SRF_RT BIT(1) +#define COMEDI_SRF_ERROR BIT(2) +#define COMEDI_SRF_RUNNING BIT(27) +#define COMEDI_SRF_FREE_SPRIV BIT(31) + +#define COMEDI_SRF_BUSY_MASK (COMEDI_SRF_ERROR | COMEDI_SRF_RUNNING) + +/** * struct comedi_file - per-file private data for comedi device * @dev: comedi_device struct * @read_subdev: current "read" subdevice diff --git a/drivers/staging/comedi/comedidev.h b/drivers/staging/comedi/comedidev.h index 52071f7..28f2606 100644 --- a/drivers/staging/comedi/comedidev.h +++ b/drivers/staging/comedi/comedidev.h @@ -303,23 +303,6 @@ void comedi_event(struct comedi_device *dev, struct comedi_subdevice *s); struct comedi_device *comedi_dev_get_from_minor(unsigned minor); int comedi_dev_put(struct comedi_device *dev); -/** - * comedi_subdevice "runflags" - * @COMEDI_SRF_RT: DEPRECATED: command is running real-time - * @COMEDI_SRF_ERROR: indicates an COMEDI_CB_ERROR event has occurred - * since the last command was started - * @COMEDI_SRF_RUNNING: command is running - * @COMEDI_SRF_FREE_SPRIV: free s->private on detach - * - * @COMEDI_SRF_BUSY_MASK: runflags that indicate the subdevice is "busy" - */ -#define COMEDI_SRF_RT BIT(1) -#define COMEDI_SRF_ERROR BIT(2) -#define COMEDI_SRF_RUNNING BIT(27) -#define COMEDI_SRF_FREE_SPRIV BIT(31) - -#define COMEDI_SRF_BUSY_MASK (COMEDI_SRF_ERROR | COMEDI_SRF_RUNNING) - bool comedi_is_subdevice_running(struct comedi_subdevice *s); void *comedi_alloc_spriv(struct comedi_subdevice *s, size_t size); -- 2.1.4 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/