linux/drivers/scsi/libsas/sas_discover.c

// SPDX-License-Identifier: GPL-2.0
/*
 * Serial Attached SCSI (SAS) Discover process
 *
 * Copyright (C) 2005 Adaptec, Inc.  All rights reserved.
 * Copyright (C) 2005 Luben Tuikov <[email protected]>
 */

#include <linux/scatterlist.h>
#include <linux/slab.h>
#include <scsi/scsi_host.h>
#include <scsi/scsi_eh.h>
#include "sas_internal.h"

#include <scsi/scsi_transport.h>
#include <scsi/scsi_transport_sas.h>
#include <scsi/sas_ata.h>
#include "scsi_sas_internal.h"

/* ---------- Basic task processing for discovery purposes ---------- */

void sas_init_dev(struct domain_device *dev)
{}

/* ---------- Domain device discovery ---------- */

/**
 * sas_get_port_device - Discover devices which caused port creation
 * @port: pointer to struct sas_port of interest
 *
 * Devices directly attached to a HA port, have no parent.  This is
 * how we know they are (domain) "root" devices.  All other devices
 * do, and should have their "parent" pointer set appropriately as
 * soon as a child device is discovered.
 */
static int sas_get_port_device(struct asd_sas_port *port)
{}

/* ---------- Discover and Revalidate ---------- */

int sas_notify_lldd_dev_found(struct domain_device *dev)
{}


void sas_notify_lldd_dev_gone(struct domain_device *dev)
{}

static void sas_probe_devices(struct asd_sas_port *port)
{}

static void sas_suspend_devices(struct work_struct *work)
{}

static void sas_resume_devices(struct work_struct *work)
{}

/**
 * sas_discover_end_dev - discover an end device (SSP, etc)
 * @dev: pointer to domain device of interest
 *
 * See comment in sas_discover_sata().
 */
static int sas_discover_end_dev(struct domain_device *dev)
{}

/* ---------- Device registration and unregistration ---------- */

void sas_free_device(struct kref *kref)
{}

static void sas_unregister_common_dev(struct asd_sas_port *port, struct domain_device *dev)
{}

void sas_destruct_devices(struct asd_sas_port *port)
{}

static void sas_destruct_ports(struct asd_sas_port *port)
{}

static bool sas_abort_cmd(struct request *req, void *data)
{}

static void sas_abort_device_scsi_cmds(struct domain_device *dev)
{}

void sas_unregister_dev(struct asd_sas_port *port, struct domain_device *dev)
{}

void sas_unregister_domain_devices(struct asd_sas_port *port, int gone)
{}

void sas_device_set_phy(struct domain_device *dev, struct sas_port *port)
{}

/* ---------- Discovery and Revalidation ---------- */

/**
 * sas_discover_domain - discover the domain
 * @work: work structure embedded in port domain device.
 *
 * NOTE: this process _must_ quit (return) as soon as any connection
 * errors are encountered.  Connection recovery is done elsewhere.
 * Discover process only interrogates devices in order to discover the
 * domain.
 */
static void sas_discover_domain(struct work_struct *work)
{}

static void sas_revalidate_domain(struct work_struct *work)
{}

/* ---------- Events ---------- */

static void sas_chain_work(struct sas_ha_struct *ha, struct sas_work *sw)
{}

static void sas_chain_event(int event, unsigned long *pending,
			    struct sas_work *sw,
			    struct sas_ha_struct *ha)
{}

void sas_discover_event(struct asd_sas_port *port, enum discover_event ev)
{}

/**
 * sas_init_disc - initialize the discovery struct in the port
 * @disc: port discovery structure
 * @port: pointer to struct port
 *
 * Called when the ports are being initialized.
 */
void sas_init_disc(struct sas_discovery *disc, struct asd_sas_port *port)
{}