linux/drivers/i2c/busses/i2c-parport.c

// SPDX-License-Identifier: GPL-2.0-or-later
/* ------------------------------------------------------------------------ *
 * i2c-parport.c I2C bus over parallel port                                 *
 * ------------------------------------------------------------------------ *
   Copyright (C) 2003-2011 Jean Delvare <[email protected]>

   Based on older i2c-philips-par.c driver
   Copyright (C) 1995-2000 Simon G. Vogl
   With some changes from:
   Frodo Looijaard <[email protected]>
   Kyösti Mälkki <[email protected]>

 * ------------------------------------------------------------------------ */

#define pr_fmt(fmt)

#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/init.h>
#include <linux/delay.h>
#include <linux/parport.h>
#include <linux/i2c.h>
#include <linux/i2c-algo-bit.h>
#include <linux/i2c-smbus.h>
#include <linux/slab.h>
#include <linux/list.h>
#include <linux/mutex.h>

#define PORT_DATA
#define PORT_STAT
#define PORT_CTRL

struct lineop {};

struct adapter_parm {};

static const struct adapter_parm adapter_parm[] =;

/* ----- Device list ------------------------------------------------------ */

struct i2c_par {};

static LIST_HEAD(adapter_list);
static DEFINE_MUTEX(adapter_list_lock);

#define MAX_DEVICE
static int parport[MAX_DEVICE] =;
module_param_array();
MODULE_PARM_DESC();

static int type =;
module_param(type, int, 0);
MODULE_PARM_DESC();

/* ----- Low-level parallel port access ----------------------------------- */

static void port_write_data(struct parport *p, unsigned char d)
{}

static void port_write_control(struct parport *p, unsigned char d)
{}

static unsigned char port_read_data(struct parport *p)
{}

static unsigned char port_read_status(struct parport *p)
{}

static unsigned char port_read_control(struct parport *p)
{}

static void (* const port_write[])(struct parport *, unsigned char) =;

static unsigned char (* const port_read[])(struct parport *) =;

/* ----- Unified line operation functions --------------------------------- */

static inline void line_set(struct parport *data, int state,
	const struct lineop *op)
{}

static inline int line_get(struct parport *data,
	const struct lineop *op)
{}

/* ----- I2C algorithm call-back functions and structures ----------------- */

static void parport_setscl(void *data, int state)
{}

static void parport_setsda(void *data, int state)
{}

static int parport_getscl(void *data)
{}

static int parport_getsda(void *data)
{}

/* Encapsulate the functions above in the correct structure.
   Note that this is only a template, from which the real structures are
   copied. The attaching code will set getscl to NULL for adapters that
   cannot read SCL back, and will also make the data field point to
   the parallel port structure. */
static const struct i2c_algo_bit_data parport_algo_data =;

/* ----- I2c and parallel port call-back functions and structures --------- */

static void i2c_parport_irq(void *data)
{}

static void i2c_parport_attach(struct parport *port)
{}

static void i2c_parport_detach(struct parport *port)
{}

static struct parport_driver i2c_parport_driver =;
module_parport_driver();

MODULE_AUTHOR();
MODULE_DESCRIPTION();
MODULE_LICENSE();