Fix sparse warning for non-ANSI function declaration.
Declare workqueue structs as static.
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Cc: Robert Love <robert.w.love@intel.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
EXPORT_SYMBOL(fc_cpu_mask);
static u16 fc_cpu_order; /* 2's power to represent total possible cpus */
static struct kmem_cache *fc_em_cachep; /* cache for exchanges */
EXPORT_SYMBOL(fc_cpu_mask);
static u16 fc_cpu_order; /* 2's power to represent total possible cpus */
static struct kmem_cache *fc_em_cachep; /* cache for exchanges */
-struct workqueue_struct *fc_exch_workqueue;
+static struct workqueue_struct *fc_exch_workqueue;
/*
* Structure and function definitions for managing Fibre Channel Exchanges
/*
* Structure and function definitions for managing Fibre Channel Exchanges
/**
* fc_setup_exch_mgr() - Setup an exchange manager
*/
/**
* fc_setup_exch_mgr() - Setup an exchange manager
*/
+int fc_setup_exch_mgr(void)
{
fc_em_cachep = kmem_cache_create("libfc_em", sizeof(struct fc_exch),
0, SLAB_HWCACHE_ALIGN, NULL);
{
fc_em_cachep = kmem_cache_create("libfc_em", sizeof(struct fc_exch),
0, SLAB_HWCACHE_ALIGN, NULL);
/**
* fc_destroy_exch_mgr() - Destroy an exchange manager
*/
/**
* fc_destroy_exch_mgr() - Destroy an exchange manager
*/
-void fc_destroy_exch_mgr()
+void fc_destroy_exch_mgr(void)
{
destroy_workqueue(fc_exch_workqueue);
kmem_cache_destroy(fc_em_cachep);
{
destroy_workqueue(fc_exch_workqueue);
kmem_cache_destroy(fc_em_cachep);
-struct kmem_cache *scsi_pkt_cachep;
+static struct kmem_cache *scsi_pkt_cachep;
/* SRB state definitions */
#define FC_SRB_FREE 0 /* cmd is free */
/* SRB state definitions */
#define FC_SRB_FREE 0 /* cmd is free */
}
EXPORT_SYMBOL(fc_fcp_destroy);
}
EXPORT_SYMBOL(fc_fcp_destroy);
+void fc_destroy_fcp(void)
{
if (scsi_pkt_cachep)
kmem_cache_destroy(scsi_pkt_cachep);
{
if (scsi_pkt_cachep)
kmem_cache_destroy(scsi_pkt_cachep);
-struct workqueue_struct *rport_event_queue;
+static struct workqueue_struct *rport_event_queue;
static void fc_rport_enter_flogi(struct fc_rport_priv *);
static void fc_rport_enter_plogi(struct fc_rport_priv *);
static void fc_rport_enter_flogi(struct fc_rport_priv *);
static void fc_rport_enter_plogi(struct fc_rport_priv *);
/**
* fc_setup_rport() - Initialize the rport_event_queue
*/
/**
* fc_setup_rport() - Initialize the rport_event_queue
*/
+int fc_setup_rport(void)
{
rport_event_queue = create_singlethread_workqueue("fc_rport_eq");
if (!rport_event_queue)
{
rport_event_queue = create_singlethread_workqueue("fc_rport_eq");
if (!rport_event_queue)
/**
* fc_destroy_rport() - Destroy the rport_event_queue
*/
/**
* fc_destroy_rport() - Destroy the rport_event_queue
*/
+void fc_destroy_rport(void)
{
destroy_workqueue(rport_event_queue);
}
{
destroy_workqueue(rport_event_queue);
}