[PATCH net-next-2.6 04/13] net-caif: add CAIF header files
From: <hidden>
Date: 2010-01-20 23:56:29
Subsystem:
networking [general], the rest · Maintainers:
"David S. Miller", Eric Dumazet, Jakub Kicinski, Paolo Abeni, Linus Torvalds
From: Sjur Braendeland <redacted> Header files for CAIF Socket, Net Device, and link-layer registration. Signed-off-by: Sjur Braendeland <redacted> --- include/net/caif/caif_dev.h | 29 +++++++++++++++++++++++++++++ include/net/caif/caif_device.h | 34 ++++++++++++++++++++++++++++++++++ 2 files changed, 63 insertions(+), 0 deletions(-)
diff --git a/include/net/caif/caif_dev.h b/include/net/caif/caif_dev.h
new file mode 100644
index 0000000..eee7f3a
--- /dev/null
+++ b/include/net/caif/caif_dev.h@@ -0,0 +1,29 @@ +/* + * Copyright (C) ST-Ericsson AB 2010 + * Author: Sjur Brendeland/ sjur.brandeland@stericsson.com + * License terms: GNU General Public License (GPL) version 2 + */ + +#ifndef CAIF_DEV_H_ +#define CAIF_DEV_H_ + +#include <net/caif/generic/caif_layer.h> +#include <net/caif/generic/cfcnfg.h> +#include <linux/caif/caif_config.h> +#include <linux/if.h> + +struct caif_service_config; +int caifdev_adapt_register(struct caif_channel_config *config, + struct layer *adap_layer); +int caifdev_adapt_unregister(struct layer *adap_layer); +struct cfcnfg *get_caif_conf(void); +void caif_register_ioctl(int (*ioctl)(unsigned int cmd, + unsigned long arg, + bool)); +int caif_ioctl(unsigned int cmd, unsigned long arg, bool from_use_land); +void caif_unregister_netdev(void); +int channel_config_2_link_param(struct cfcnfg *cnfg, + struct caif_channel_config *s, + struct cfctrl_link_param *l); + +#endif /* CAIF_DEV_H_ */
diff --git a/include/net/caif/caif_device.h b/include/net/caif/caif_device.h
new file mode 100644
index 0000000..6752bb7
--- /dev/null
+++ b/include/net/caif/caif_device.h@@ -0,0 +1,34 @@ +/* + * Copyright (C) ST-Ericsson AB 2010 + * Author: Sjur Brendeland/ sjur.brandeland@stericsson.com + * License terms: GNU General Public License (GPL) version 2 + */ + +#ifndef CAIF_DEVICE_H_ +#define CAIF_DEVICE_H_ +#include <linux/kernel.h> +#include <linux/net.h> +#include <linux/netdevice.h> +#include <linux/caif/caif_socket.h> +#include <net/caif/caif_device.h> + +/** + * struct caif_dev_common - shared between CAIF drivers and stack . + * @flowctrl: Flow Control callback function. + * @link_select: Indicate bandwidth and latency of device. + * @use_frag: CAIF Frames may be framented. + * @use_fcs: Indicate if Frame CheckSum (fcs) is used. + * @use_stx: Indicate STart of frame eXtension (stx) in use. + * + * This structure is shared between the CAIF drivers and the CAIF stack. + */ +struct caif_dev_common { + void (*flowctrl)(struct net_device *net, int on); + enum caif_link_selector link_select; + int use_frag; + int use_fcs; + int use_stx; +}; + +#endif /* CAIF_DEVICE_H_ */ +
--
1.6.3.3