lkml.org 
[lkml]   [2015]   [Jun]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 06/32] staging: comedi: das08.h: make self-reliant
Date
The Comedi "das08.h" header file is included by drivers for the
ComputerBoards/MeasurementComputing and Keithley Metrabyte boards in the
DAS08 series. It does not compile cleanly when it is the first header
included by the ".c" file. It uses `struct comedi_device *` in the
parameter list of a function prototype, so just declare `struct
comedi_device` as an incomplete type. It also uses `bool`, so include
<linux/types.h> to declare it.

Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
---
drivers/staging/comedi/drivers/das08.h | 4 ++++
1 file changed, 4 insertions(+)

diff --git a/drivers/staging/comedi/drivers/das08.h b/drivers/staging/comedi/drivers/das08.h
index 8b1c1a9..d27044c 100644
--- a/drivers/staging/comedi/drivers/das08.h
+++ b/drivers/staging/comedi/drivers/das08.h
@@ -19,6 +19,10 @@
#ifndef _DAS08_H
#define _DAS08_H

+#include <linux/types.h>
+
+struct comedi_device;
+
/* different ways ai data is encoded in first two registers */
enum das08_ai_encoding { das08_encode12, das08_encode16, das08_pcm_encode12 };
/* types of ai range table used by different boards */
--
2.1.4


\
 
 \ /
  Last update: 2015-06-05 20:01    [W:0.088 / U:0.268 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site