linux/drivers/pnp/card.c

// SPDX-License-Identifier: GPL-2.0
/*
 * card.c - contains functions for managing groups of PnP devices
 *
 * Copyright 2002 Adam Belay <[email protected]>
 */

#include <linux/module.h>
#include <linux/mutex.h>
#include <linux/ctype.h>
#include <linux/slab.h>
#include <linux/pnp.h>
#include <linux/dma-mapping.h>
#include "base.h"

LIST_HEAD();
static LIST_HEAD(pnp_card_drivers);

static const struct pnp_card_device_id *match_card(struct pnp_card_driver *drv,
						   struct pnp_card *card)
{}

static void card_remove(struct pnp_dev *dev)
{}

static void card_remove_first(struct pnp_dev *dev)
{}

static int card_probe(struct pnp_card *card, struct pnp_card_driver *drv)
{}

/**
 * pnp_add_card_id - adds an EISA id to the specified card
 * @id: pointer to a pnp_id structure
 * @card: pointer to the desired card
 */
static struct pnp_id *pnp_add_card_id(struct pnp_card *card, char *id)
{}

static void pnp_free_card_ids(struct pnp_card *card)
{}

static void pnp_release_card(struct device *dmdev)
{}

struct pnp_card *pnp_alloc_card(struct pnp_protocol *protocol, int id, char *pnpid)
{}

static ssize_t name_show(struct device *dmdev,
			 struct device_attribute *attr, char *buf)
{}

static DEVICE_ATTR_RO(name);

static ssize_t card_id_show(struct device *dmdev,
			    struct device_attribute *attr, char *buf)
{}

static DEVICE_ATTR_RO(card_id);

static int pnp_interface_attach_card(struct pnp_card *card)
{}

/**
 * pnp_add_card - adds a PnP card to the PnP Layer
 * @card: pointer to the card to add
 */
int pnp_add_card(struct pnp_card *card)
{}

/**
 * pnp_remove_card - removes a PnP card from the PnP Layer
 * @card: pointer to the card to remove
 */
void pnp_remove_card(struct pnp_card *card)
{}

/**
 * pnp_add_card_device - adds a device to the specified card
 * @card: pointer to the card to add to
 * @dev: pointer to the device to add
 */
int pnp_add_card_device(struct pnp_card *card, struct pnp_dev *dev)
{}

/**
 * pnp_remove_card_device- removes a device from the specified card
 * @dev: pointer to the device to remove
 */
void pnp_remove_card_device(struct pnp_dev *dev)
{}

/**
 * pnp_request_card_device - Searches for a PnP device under the specified card
 * @clink: pointer to the card link, cannot be NULL
 * @id: pointer to a PnP ID structure that explains the rules for finding the device
 * @from: Starting place to search from. If NULL it will start from the beginning.
 */
struct pnp_dev *pnp_request_card_device(struct pnp_card_link *clink,
					const char *id, struct pnp_dev *from)
{}
EXPORT_SYMBOL();

/**
 * pnp_release_card_device - call this when the driver no longer needs the device
 * @dev: pointer to the PnP device structure
 */
void pnp_release_card_device(struct pnp_dev *dev)
{}
EXPORT_SYMBOL();

/*
 * suspend/resume callbacks
 */
static int card_suspend(struct pnp_dev *dev, pm_message_t state)
{}

static int card_resume(struct pnp_dev *dev)
{}

/**
 * pnp_register_card_driver - registers a PnP card driver with the PnP Layer
 * @drv: pointer to the driver to register
 */
int pnp_register_card_driver(struct pnp_card_driver *drv)
{}
EXPORT_SYMBOL();

/**
 * pnp_unregister_card_driver - unregisters a PnP card driver from the PnP Layer
 * @drv: pointer to the driver to unregister
 */
void pnp_unregister_card_driver(struct pnp_card_driver *drv)
{}
EXPORT_SYMBOL();