linux/drivers/scsi/libsas/sas_init.c

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

#include <linux/module.h>
#include <linux/slab.h>
#include <linux/init.h>
#include <linux/device.h>
#include <linux/spinlock.h>
#include <scsi/sas_ata.h>
#include <scsi/scsi_host.h>
#include <scsi/scsi_device.h>
#include <scsi/scsi_transport.h>
#include <scsi/scsi_transport_sas.h>

#include "sas_internal.h"

#include "scsi_sas_internal.h"

static struct kmem_cache *sas_task_cache;
static struct kmem_cache *sas_event_cache;

struct sas_task *sas_alloc_task(gfp_t flags)
{}

struct sas_task *sas_alloc_slow_task(gfp_t flags)
{}

void sas_free_task(struct sas_task *task)
{}

/*------------ SAS addr hash -----------*/
void sas_hash_addr(u8 *hashed, const u8 *sas_addr)
{}

int sas_register_ha(struct sas_ha_struct *sas_ha)
{}
EXPORT_SYMBOL_GPL();

static void sas_disable_events(struct sas_ha_struct *sas_ha)
{}

int sas_unregister_ha(struct sas_ha_struct *sas_ha)
{}
EXPORT_SYMBOL_GPL();

static int sas_get_linkerrors(struct sas_phy *phy)
{}

int sas_try_ata_reset(struct asd_sas_phy *asd_phy)
{}

/*
 * transport_sas_phy_reset - reset a phy and permit libata to manage the link
 *
 * phy reset request via sysfs in host workqueue context so we know we
 * can block on eh and safely traverse the domain_device topology
 */
static int transport_sas_phy_reset(struct sas_phy *phy, int hard_reset)
{}

int sas_phy_enable(struct sas_phy *phy, int enable)
{}
EXPORT_SYMBOL_GPL();

int sas_phy_reset(struct sas_phy *phy, int hard_reset)
{}
EXPORT_SYMBOL_GPL();

static int sas_set_phy_speed(struct sas_phy *phy,
			     struct sas_phy_linkrates *rates)
{}

void sas_prep_resume_ha(struct sas_ha_struct *ha)
{}
EXPORT_SYMBOL();

static int phys_suspended(struct sas_ha_struct *ha)
{}

static void sas_resume_insert_broadcast_ha(struct sas_ha_struct *ha)
{}

static void _sas_resume_ha(struct sas_ha_struct *ha, bool drain)
{}

void sas_resume_ha(struct sas_ha_struct *ha)
{}
EXPORT_SYMBOL();

/* A no-sync variant, which does not call sas_drain_ha(). */
void sas_resume_ha_no_sync(struct sas_ha_struct *ha)
{}
EXPORT_SYMBOL();

void sas_suspend_ha(struct sas_ha_struct *ha)
{}
EXPORT_SYMBOL();

static void sas_phy_release(struct sas_phy *phy)
{}

static void phy_reset_work(struct work_struct *work)
{}

static void phy_enable_work(struct work_struct *work)
{}

static int sas_phy_setup(struct sas_phy *phy)
{}

static int queue_phy_reset(struct sas_phy *phy, int hard_reset)
{}

static int queue_phy_enable(struct sas_phy *phy, int enable)
{}

static struct sas_function_template sft =;

static inline ssize_t phy_event_threshold_show(struct device *dev,
			struct device_attribute *attr, char *buf)
{}

static inline ssize_t phy_event_threshold_store(struct device *dev,
			struct device_attribute *attr,
			const char *buf, size_t count)
{}

DEVICE_ATTR();
EXPORT_SYMBOL_GPL();

struct scsi_transport_template *
sas_domain_attach_transport(struct sas_domain_function_template *dft)
{}
EXPORT_SYMBOL_GPL();

struct asd_sas_event *sas_alloc_event(struct asd_sas_phy *phy,
				      gfp_t gfp_flags)
{}

void sas_free_event(struct asd_sas_event *event)
{}

/* ---------- SAS Class register/unregister ---------- */

static int __init sas_class_init(void)
{}

static void __exit sas_class_exit(void)
{}

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

module_init();
module_exit(sas_class_exit);