Commit 2098dbd1 authored by Benjamin Romer's avatar Benjamin Romer Committed by Greg Kroah-Hartman

staging: unisys: remove LOGINF macros

Remove the LOGINF, LOGINFDEV, LOGINFDEVX, LOGINFNAME, PRINTKDRV, and
INFODRV macros entirely from the driver set.
Signed-off-by: default avatarBenjamin Romer <benjamin.romer@unisys.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 4de57acb
...@@ -87,13 +87,11 @@ ...@@ -87,13 +87,11 @@
(void *)(p2) = SWAPPOINTERS_TEMP; \ (void *)(p2) = SWAPPOINTERS_TEMP; \
} while (0) } while (0)
#define PRINTKDRV(fmt, args...) LOGINF(fmt, ## args)
#define TBDDRV(fmt, args...) LOGERR(fmt, ## args) #define TBDDRV(fmt, args...) LOGERR(fmt, ## args)
#define HUHDRV(fmt, args...) LOGERR(fmt, ## args) #define HUHDRV(fmt, args...) LOGERR(fmt, ## args)
#define ERRDRV(fmt, args...) LOGERR(fmt, ## args) #define ERRDRV(fmt, args...) LOGERR(fmt, ## args)
#define WARNDRV(fmt, args...) LOGWRN(fmt, ## args) #define WARNDRV(fmt, args...) LOGWRN(fmt, ## args)
#define SECUREDRV(fmt, args...) LOGWRN(fmt, ## args) #define SECUREDRV(fmt, args...) LOGWRN(fmt, ## args)
#define INFODRV(fmt, args...) LOGINF(fmt, ## args)
#define PRINTKDEV(devname, fmt, args...) LOGINFDEV(devname, fmt, ## args) #define PRINTKDEV(devname, fmt, args...) LOGINFDEV(devname, fmt, ## args)
#define TBDDEV(devname, fmt, args...) LOGERRDEV(devname, fmt, ## args) #define TBDDEV(devname, fmt, args...) LOGERRDEV(devname, fmt, ## args)
......
...@@ -25,35 +25,6 @@ ...@@ -25,35 +25,6 @@
#include <linux/printk.h> #include <linux/printk.h>
/*
* # LOGINF
*
* \brief Log informational message - logs a message at the LOG_INFO level
*
* \param devname the device name of the device reporting this message, or
* NULL if this message is NOT device-related.
* \param fmt printf()-style format string containing the message to log.
* \param args Optional arguments to be formatted and inserted into the
* format string.
* \return nothing
*
* Logs the specified message at the LOG_INFO level.
*/
#define LOGINF(fmt, args...) pr_info(fmt, ## args)
#define LOGINFDEV(devname, fmt, args...) \
pr_info("%s " fmt, devname, ## args)
#define LOGINFDEVX(devno, fmt, args...) \
pr_info("dev%d " fmt, devno, ## args)
#define LOGINFNAME(vnic, fmt, args...) \
do { \
if (vnic != NULL) { \
pr_info("%s " fmt, vnic->name, ## args); \
} else { \
pr_info(fmt, ## args); \
} \
} while (0)
/* /*
* # LOGVER * # LOGVER
* *
......
...@@ -671,8 +671,6 @@ static int destroy_device(struct controlvm_message *msg, char *buf) ...@@ -671,8 +671,6 @@ static int destroy_device(struct controlvm_message *msg, char *buf)
dev_no = msg->cmd.destroy_device.bus_no; dev_no = msg->cmd.destroy_device.bus_no;
read_lock(&bus_list_lock); read_lock(&bus_list_lock);
LOGINF("destroy_device called for bus_no=%u, dev_no=%u", bus_no,
dev_no);
for (bus = bus_list; bus; bus = bus->next) { for (bus = bus_list; bus; bus = bus->next) {
if (bus->bus_no == bus_no) { if (bus->bus_no == bus_no) {
/* make sure the device number is valid */ /* make sure the device number is valid */
...@@ -733,12 +731,10 @@ static int destroy_device(struct controlvm_message *msg, char *buf) ...@@ -733,12 +731,10 @@ static int destroy_device(struct controlvm_message *msg, char *buf)
* kernel paging request" * kernel paging request"
*/ */
if (dev->polling) { if (dev->polling) {
LOGINF("calling uislib_disable_channel_interrupts");
uislib_disable_channel_interrupts(bus_no, dev_no); uislib_disable_channel_interrupts(bus_no, dev_no);
} }
/* unmap the channel memory for the device. */ /* unmap the channel memory for the device. */
if (!msg->hdr.flags.test_message) { if (!msg->hdr.flags.test_message) {
LOGINF("destroy_device, doing iounmap");
uislib_iounmap(dev->chanptr); uislib_iounmap(dev->chanptr);
} }
kfree(dev); kfree(dev);
...@@ -806,7 +802,6 @@ uislib_client_inject_add_bus(u32 bus_no, uuid_le inst_uuid, ...@@ -806,7 +802,6 @@ uislib_client_inject_add_bus(u32 bus_no, uuid_le inst_uuid,
{ {
struct controlvm_message msg; struct controlvm_message msg;
LOGINF("enter busNo=0x%x\n", bus_no);
/* step 0: init the chipset */ /* step 0: init the chipset */
POSTCODE_LINUX_3(CHIPSET_INIT_ENTRY_PC, bus_no, POSTCODE_SEVERITY_INFO); POSTCODE_LINUX_3(CHIPSET_INIT_ENTRY_PC, bus_no, POSTCODE_SEVERITY_INFO);
...@@ -826,7 +821,6 @@ uislib_client_inject_add_bus(u32 bus_no, uuid_le inst_uuid, ...@@ -826,7 +821,6 @@ uislib_client_inject_add_bus(u32 bus_no, uuid_le inst_uuid,
LOGERR("init_chipset failed.\n"); LOGERR("init_chipset failed.\n");
return 0; return 0;
} }
LOGINF("chipset initialized\n");
POSTCODE_LINUX_3(CHIPSET_INIT_EXIT_PC, bus_no, POSTCODE_LINUX_3(CHIPSET_INIT_EXIT_PC, bus_no,
POSTCODE_SEVERITY_INFO); POSTCODE_SEVERITY_INFO);
} }
...@@ -906,7 +900,6 @@ uislib_client_inject_add_vhba(u32 bus_no, u32 dev_no, ...@@ -906,7 +900,6 @@ uislib_client_inject_add_vhba(u32 bus_no, u32 dev_no,
{ {
struct controlvm_message msg; struct controlvm_message msg;
LOGINF(" enter busNo=0x%x devNo=0x%x\n", bus_no, dev_no);
/* chipset init'ed with bus bus has been previously created - /* chipset init'ed with bus bus has been previously created -
* Verify it still exists step 2: create the VHBA device on the * Verify it still exists step 2: create the VHBA device on the
* bus * bus
...@@ -965,7 +958,6 @@ uislib_client_inject_add_vnic(u32 bus_no, u32 dev_no, ...@@ -965,7 +958,6 @@ uislib_client_inject_add_vnic(u32 bus_no, u32 dev_no,
{ {
struct controlvm_message msg; struct controlvm_message msg;
LOGINF(" enter busNo=0x%x devNo=0x%x\n", bus_no, dev_no);
/* chipset init'ed with bus bus has been previously created - /* chipset init'ed with bus bus has been previously created -
* Verify it still exists step 2: create the VNIC device on the * Verify it still exists step 2: create the VNIC device on the
* bus * bus
...@@ -1249,7 +1241,6 @@ static int process_incoming(void *v) ...@@ -1249,7 +1241,6 @@ static int process_incoming(void *v)
wait_cycles = (cur_cycles - old_cycles); wait_cycles = (cur_cycles - old_cycles);
} }
} }
LOGINF("wait_cycles=%llu", wait_cycles);
cycles_before_wait = wait_cycles; cycles_before_wait = wait_cycles;
idle_cycles = 0; idle_cycles = 0;
poll_dev_start = 0; poll_dev_start = 0;
...@@ -1310,7 +1301,6 @@ static int process_incoming(void *v) ...@@ -1310,7 +1301,6 @@ static int process_incoming(void *v)
if (kthread_should_stop()) if (kthread_should_stop())
break; break;
if (en_smart_wakeup == 0xFF) { if (en_smart_wakeup == 0xFF) {
LOGINF("en_smart_wakeup set to 0xff, to force exiting process_incoming");
break; break;
} }
/* wait for POLLJIFFIES_NORMAL jiffies, or until /* wait for POLLJIFFIES_NORMAL jiffies, or until
...@@ -1441,27 +1431,6 @@ uislib_mod_init(void) ...@@ -1441,27 +1431,6 @@ uislib_mod_init(void)
if (!unisys_spar_platform) if (!unisys_spar_platform)
return -ENODEV; return -ENODEV;
LOGINF("MONITORAPIS");
LOGINF("sizeof(struct uiscmdrsp):%lu bytes\n",
(ulong)sizeof(struct uiscmdrsp));
LOGINF("sizeof(struct phys_info):%lu\n",
(ulong)sizeof(struct phys_info));
LOGINF("sizeof(uiscmdrsp_scsi):%lu\n",
(ulong)sizeof(struct uiscmdrsp_scsi));
LOGINF("sizeof(uiscmdrsp_net):%lu\n",
(ulong)sizeof(struct uiscmdrsp_net));
LOGINF("sizeof(CONTROLVM_MESSAGE):%lu bytes\n",
(ulong)sizeof(struct controlvm_message));
LOGINF("sizeof(struct spar_controlvm_channel_protocol):%lu bytes\n",
(ulong)sizeof(struct spar_controlvm_channel_protocol));
LOGINF("sizeof(CHANNEL_HEADER):%lu bytes\n",
(ulong)sizeof(struct channel_header));
LOGINF("sizeof(struct spar_io_channel_protocol):%lu bytes\n",
(ulong)sizeof(struct spar_io_channel_protocol));
LOGINF("SIZEOF_CMDRSP:%lu bytes\n", SIZEOF_CMDRSP);
LOGINF("SIZEOF_PROTOCOL:%lu bytes\n", SIZEOF_PROTOCOL);
/* initialize global pointers to NULL */ /* initialize global pointers to NULL */
bus_list = NULL; bus_list = NULL;
bus_list_count = 0; bus_list_count = 0;
......
...@@ -47,7 +47,6 @@ uisthread_start(struct uisthread_info *thrinfo, ...@@ -47,7 +47,6 @@ uisthread_start(struct uisthread_info *thrinfo,
return 0; /* failure */ return 0; /* failure */
} }
thrinfo->id = thrinfo->task->pid; thrinfo->id = thrinfo->task->pid;
LOGINF("started thread pid:%d\n", thrinfo->id);
return 1; return 1;
} }
EXPORT_SYMBOL_GPL(uisthread_start); EXPORT_SYMBOL_GPL(uisthread_start);
...@@ -60,16 +59,12 @@ uisthread_stop(struct uisthread_info *thrinfo) ...@@ -60,16 +59,12 @@ uisthread_stop(struct uisthread_info *thrinfo)
if (thrinfo->id == 0) if (thrinfo->id == 0)
return; /* thread not running */ return; /* thread not running */
LOGINF("uisthread_stop stopping id:%d\n", thrinfo->id);
kthread_stop(thrinfo->task); kthread_stop(thrinfo->task);
/* give up if the thread has NOT died in 1 minute */ /* give up if the thread has NOT died in 1 minute */
if (wait_for_completion_timeout(&thrinfo->has_stopped, 60 * HZ)) if (wait_for_completion_timeout(&thrinfo->has_stopped, 60 * HZ))
stopped = 1; stopped = 1;
else
LOGERR("timed out trying to signal thread\n");
if (stopped) { if (stopped) {
LOGINF("uisthread_stop stopped id:%d\n", thrinfo->id);
thrinfo->id = 0; thrinfo->id = 0;
} }
} }
......
...@@ -74,8 +74,6 @@ int ...@@ -74,8 +74,6 @@ int
uisctrl_register_req_handler(int type, void *fptr, uisctrl_register_req_handler(int type, void *fptr,
struct ultra_vbus_deviceinfo *chipset_driver_info) struct ultra_vbus_deviceinfo *chipset_driver_info)
{ {
LOGINF("type = %d, fptr = 0x%p.\n", type, fptr);
switch (type) { switch (type) {
case 2: case 2:
if (fptr) { if (fptr) {
......
...@@ -469,9 +469,6 @@ virthba_probe(struct virtpci_dev *virtpcidev, const struct pci_device_id *id) ...@@ -469,9 +469,6 @@ virthba_probe(struct virtpci_dev *virtpcidev, const struct pci_device_id *id)
LOGVER("virtpcidev bus_no<<%d>>devNo<<%d>>", virtpcidev->bus_no, LOGVER("virtpcidev bus_no<<%d>>devNo<<%d>>", virtpcidev->bus_no,
virtpcidev->device_no); virtpcidev->device_no);
LOGINF("entering virthba_probe...\n");
LOGINF("virtpcidev bus_no<<%d>>devNo<<%d>>", virtpcidev->bus_no,
virtpcidev->device_no);
POSTCODE_LINUX_2(VHBA_PROBE_ENTRY_PC, POSTCODE_SEVERITY_INFO); POSTCODE_LINUX_2(VHBA_PROBE_ENTRY_PC, POSTCODE_SEVERITY_INFO);
/* call scsi_host_alloc to register a scsi host adapter /* call scsi_host_alloc to register a scsi host adapter
* instance - this virthba that has just been created is an * instance - this virthba that has just been created is an
...@@ -497,12 +494,6 @@ virthba_probe(struct virtpci_dev *virtpcidev, const struct pci_device_id *id) ...@@ -497,12 +494,6 @@ virthba_probe(struct virtpci_dev *virtpcidev, const struct pci_device_id *id)
* scan is 0 to max (inclusive); so we will subtract one from * scan is 0 to max (inclusive); so we will subtract one from
* the max-channel value. * the max-channel value.
*/ */
LOGINF("virtpcidev->scsi.max.max_channel=%u, max_id=%u, max_lun=%u, cmd_per_lun=%u, max_io_size=%u\n",
(unsigned)virtpcidev->scsi.max.max_channel - 1,
(unsigned)virtpcidev->scsi.max.max_id,
(unsigned)virtpcidev->scsi.max.max_lun,
(unsigned)virtpcidev->scsi.max.cmd_per_lun,
(unsigned)virtpcidev->scsi.max.max_io_size);
scsihost->max_channel = (unsigned)virtpcidev->scsi.max.max_channel; scsihost->max_channel = (unsigned)virtpcidev->scsi.max.max_channel;
scsihost->max_id = (unsigned)virtpcidev->scsi.max.max_id; scsihost->max_id = (unsigned)virtpcidev->scsi.max.max_id;
scsihost->max_lun = (unsigned)virtpcidev->scsi.max.max_lun; scsihost->max_lun = (unsigned)virtpcidev->scsi.max.max_lun;
...@@ -513,13 +504,6 @@ virthba_probe(struct virtpci_dev *virtpcidev, const struct pci_device_id *id) ...@@ -513,13 +504,6 @@ virthba_probe(struct virtpci_dev *virtpcidev, const struct pci_device_id *id)
(unsigned short)(virtpcidev->scsi.max.max_io_size / PAGE_SIZE); (unsigned short)(virtpcidev->scsi.max.max_io_size / PAGE_SIZE);
if (scsihost->sg_tablesize > MAX_PHYS_INFO) if (scsihost->sg_tablesize > MAX_PHYS_INFO)
scsihost->sg_tablesize = MAX_PHYS_INFO; scsihost->sg_tablesize = MAX_PHYS_INFO;
LOGINF("scsihost->max_channel=%u, max_id=%u, max_lun=%llu, cmd_per_lun=%u, max_sectors=%hu, sg_tablesize=%hu\n",
scsihost->max_channel, scsihost->max_id, scsihost->max_lun,
scsihost->cmd_per_lun, scsihost->max_sectors,
scsihost->sg_tablesize);
LOGINF("scsihost->can_queue=%u, scsihost->cmd_per_lun=%u, max_sectors=%hu, sg_tablesize=%hu\n",
scsihost->can_queue, scsihost->cmd_per_lun, scsihost->max_sectors,
scsihost->sg_tablesize);
/* this creates "host%d" in sysfs. If 2nd argument is NULL, /* this creates "host%d" in sysfs. If 2nd argument is NULL,
* then this generic /sys/devices/platform/host? device is * then this generic /sys/devices/platform/host? device is
...@@ -591,15 +575,6 @@ virthba_probe(struct virtpci_dev *virtpcidev, const struct pci_device_id *id) ...@@ -591,15 +575,6 @@ virthba_probe(struct virtpci_dev *virtpcidev, const struct pci_device_id *id)
scsi_host_put(scsihost); scsi_host_put(scsihost);
return -ENODEV; return -ENODEV;
} }
LOGINF("sendInterruptHandle=0x%16llX",
virthbainfo->intr.send_irq_handle);
LOGINF("recvInterruptHandle=0x%16llX",
virthbainfo->intr.recv_irq_handle);
LOGINF("recvInterruptVector=0x%8X",
virthbainfo->intr.recv_irq_vector);
LOGINF("recvInterruptShared=0x%2X",
virthbainfo->intr.recv_irq_shared);
LOGINF("scsihost.hostt->name=%s", scsihost->hostt->name);
virthbainfo->interrupt_vector = virthbainfo->interrupt_vector =
virthbainfo->intr.recv_irq_handle & INTERRUPT_VECTOR_MASK; virthbainfo->intr.recv_irq_handle & INTERRUPT_VECTOR_MASK;
rsp = request_irq(virthbainfo->interrupt_vector, handler, IRQF_SHARED, rsp = request_irq(virthbainfo->interrupt_vector, handler, IRQF_SHARED,
...@@ -624,7 +599,6 @@ virthba_probe(struct virtpci_dev *virtpcidev, const struct pci_device_id *id) ...@@ -624,7 +599,6 @@ virthba_probe(struct virtpci_dev *virtpcidev, const struct pci_device_id *id)
scsi_scan_host(scsihost); scsi_scan_host(scsihost);
LOGINF("virthba added scsihost:0x%p\n", scsihost);
POSTCODE_LINUX_2(VHBA_PROBE_EXIT_PC, POSTCODE_SEVERITY_INFO); POSTCODE_LINUX_2(VHBA_PROBE_EXIT_PC, POSTCODE_SEVERITY_INFO);
return 0; return 0;
} }
...@@ -636,13 +610,9 @@ virthba_remove(struct virtpci_dev *virtpcidev) ...@@ -636,13 +610,9 @@ virthba_remove(struct virtpci_dev *virtpcidev)
struct Scsi_Host *scsihost = struct Scsi_Host *scsihost =
(struct Scsi_Host *)virtpcidev->scsi.scsihost; (struct Scsi_Host *)virtpcidev->scsi.scsihost;
LOGINF("virtpcidev bus_no<<%d>>devNo<<%d>>", virtpcidev->bus_no,
virtpcidev->device_no);
virthbainfo = (struct virthba_info *)scsihost->hostdata; virthbainfo = (struct virthba_info *)scsihost->hostdata;
if (virthbainfo->interrupt_vector != -1) if (virthbainfo->interrupt_vector != -1)
free_irq(virthbainfo->interrupt_vector, virthbainfo); free_irq(virthbainfo->interrupt_vector, virthbainfo);
LOGINF("Removing virtpcidev: 0x%p, virthbainfo: 0x%p\n", virtpcidev,
virthbainfo);
scsi_remove_host(scsihost); scsi_remove_host(scsihost);
...@@ -652,7 +622,6 @@ virthba_remove(struct virtpci_dev *virtpcidev) ...@@ -652,7 +622,6 @@ virthba_remove(struct virtpci_dev *virtpcidev)
* scsi_add_host so the scsi_host gets deleted * scsi_add_host so the scsi_host gets deleted
*/ */
scsi_host_put(scsihost); scsi_host_put(scsihost);
LOGINF("virthba removed scsi_host.\n");
} }
static int static int
...@@ -666,9 +635,6 @@ forward_vdiskmgmt_command(enum vdisk_mgmt_types vdiskcmdtype, ...@@ -666,9 +635,6 @@ forward_vdiskmgmt_command(enum vdisk_mgmt_types vdiskcmdtype,
int notifyresult = 0xffff; int notifyresult = 0xffff;
wait_queue_head_t notifyevent; wait_queue_head_t notifyevent;
LOGINF("vDiskMgmt:%d %d:%d:%d\n", vdiskcmdtype,
vdest->channel, vdest->id, vdest->lun);
if (virthbainfo->serverdown || virthbainfo->serverchangingstate) if (virthbainfo->serverdown || virthbainfo->serverchangingstate)
return FAILED; return FAILED;
...@@ -703,10 +669,7 @@ forward_vdiskmgmt_command(enum vdisk_mgmt_types vdiskcmdtype, ...@@ -703,10 +669,7 @@ forward_vdiskmgmt_command(enum vdisk_mgmt_types vdiskcmdtype,
&virthbainfo->chinfo.insertlock, &virthbainfo->chinfo.insertlock,
DONT_ISSUE_INTERRUPT, (u64)NULL, DONT_ISSUE_INTERRUPT, (u64)NULL,
OK_TO_WAIT, "vhba"); OK_TO_WAIT, "vhba");
LOGINF("VdiskMgmt waiting on event notifyevent=0x%p\n",
cmdrsp->scsitaskmgmt.notify);
wait_event(notifyevent, notifyresult != 0xffff); wait_event(notifyevent, notifyresult != 0xffff);
LOGINF("VdiskMgmt complete; result:%d\n", cmdrsp->vdiskmgmt.result);
kfree(cmdrsp); kfree(cmdrsp);
return SUCCESS; return SUCCESS;
} }
...@@ -725,9 +688,6 @@ forward_taskmgmt_command(enum task_mgmt_types tasktype, ...@@ -725,9 +688,6 @@ forward_taskmgmt_command(enum task_mgmt_types tasktype,
int notifyresult = 0xffff; int notifyresult = 0xffff;
wait_queue_head_t notifyevent; wait_queue_head_t notifyevent;
LOGINF("TaskMgmt:%d %d:%d:%llu\n", tasktype,
scsidev->channel, scsidev->id, scsidev->lun);
if (virthbainfo->serverdown || virthbainfo->serverchangingstate) if (virthbainfo->serverdown || virthbainfo->serverchangingstate)
return FAILED; return FAILED;
...@@ -761,10 +721,7 @@ forward_taskmgmt_command(enum task_mgmt_types tasktype, ...@@ -761,10 +721,7 @@ forward_taskmgmt_command(enum task_mgmt_types tasktype,
&virthbainfo->chinfo.insertlock, &virthbainfo->chinfo.insertlock,
DONT_ISSUE_INTERRUPT, (u64)NULL, DONT_ISSUE_INTERRUPT, (u64)NULL,
OK_TO_WAIT, "vhba"); OK_TO_WAIT, "vhba");
LOGINF("TaskMgmt waiting on event notifyevent=0x%p\n",
cmdrsp->scsitaskmgmt.notify);
wait_event(notifyevent, notifyresult != 0xffff); wait_event(notifyevent, notifyresult != 0xffff);
LOGINF("TaskMgmt complete; result:%d\n", cmdrsp->scsitaskmgmt.result);
kfree(cmdrsp); kfree(cmdrsp);
return SUCCESS; return SUCCESS;
} }
...@@ -958,9 +915,6 @@ virthba_queue_command_lck(struct scsi_cmnd *scsicmd, ...@@ -958,9 +915,6 @@ virthba_queue_command_lck(struct scsi_cmnd *scsicmd,
for_each_sg(sgl, sg, scsi_sg_count(scsicmd), i) { for_each_sg(sgl, sg, scsi_sg_count(scsicmd), i) {
cmdrsp->scsi.gpi_list[i].address = sg_phys(sg); cmdrsp->scsi.gpi_list[i].address = sg_phys(sg);
cmdrsp->scsi.gpi_list[i].length = sg->length; cmdrsp->scsi.gpi_list[i].length = sg->length;
if ((i != 0) && (sg->offset != 0))
LOGINF("Offset on a sg_entry other than zero =<<%d>>.\n",
sg->offset);
} }
if (sg_failed) { if (sg_failed) {
...@@ -1208,7 +1162,6 @@ complete_vdiskmgmt_command(struct uiscmdrsp *cmdrsp) ...@@ -1208,7 +1162,6 @@ complete_vdiskmgmt_command(struct uiscmdrsp *cmdrsp)
/* wake up the error handler that is waiting for this */ /* wake up the error handler that is waiting for this */
*(int *)cmdrsp->vdiskmgmt.notifyresult = cmdrsp->vdiskmgmt.result; *(int *)cmdrsp->vdiskmgmt.notifyresult = cmdrsp->vdiskmgmt.result;
wake_up_all((wait_queue_head_t *)cmdrsp->vdiskmgmt.notify); wake_up_all((wait_queue_head_t *)cmdrsp->vdiskmgmt.notify);
LOGINF("set notify result to %d\n", cmdrsp->vdiskmgmt.result);
} }
static inline void static inline void
...@@ -1219,7 +1172,6 @@ complete_taskmgmt_command(struct uiscmdrsp *cmdrsp) ...@@ -1219,7 +1172,6 @@ complete_taskmgmt_command(struct uiscmdrsp *cmdrsp)
*(int *)cmdrsp->scsitaskmgmt.notifyresult = *(int *)cmdrsp->scsitaskmgmt.notifyresult =
cmdrsp->scsitaskmgmt.result; cmdrsp->scsitaskmgmt.result;
wake_up_all((wait_queue_head_t *)cmdrsp->scsitaskmgmt.notify); wake_up_all((wait_queue_head_t *)cmdrsp->scsitaskmgmt.notify);
LOGINF("set notify result to %d\n", cmdrsp->scsitaskmgmt.result);
} }
static void static void
...@@ -1591,8 +1543,6 @@ virthba_mod_init(void) ...@@ -1591,8 +1543,6 @@ virthba_mod_init(void)
if (!unisys_spar_platform) if (!unisys_spar_platform)
return -ENODEV; return -ENODEV;
LOGINF("Entering virthba_mod_init...\n");
POSTCODE_LINUX_2(VHBA_CREATE_ENTRY_PC, POSTCODE_SEVERITY_INFO); POSTCODE_LINUX_2(VHBA_CREATE_ENTRY_PC, POSTCODE_SEVERITY_INFO);
virthba_parse_options(virthba_options); virthba_parse_options(virthba_options);
...@@ -1630,7 +1580,6 @@ virthba_mod_init(void) ...@@ -1630,7 +1580,6 @@ virthba_mod_init(void)
} }
POSTCODE_LINUX_2(VHBA_CREATE_EXIT_PC, POSTCODE_SEVERITY_INFO); POSTCODE_LINUX_2(VHBA_CREATE_EXIT_PC, POSTCODE_SEVERITY_INFO);
LOGINF("Leaving virthba_mod_init\n");
return error; return error;
} }
...@@ -1680,8 +1629,6 @@ static DEVICE_ATTRIBUTE *virthba_shost_attrs[] = { ...@@ -1680,8 +1629,6 @@ static DEVICE_ATTRIBUTE *virthba_shost_attrs[] = {
static void __exit static void __exit
virthba_mod_exit(void) virthba_mod_exit(void)
{ {
LOGINF("entering virthba_mod_exit...\n");
virtpci_unregister_driver(&virthba_driver); virtpci_unregister_driver(&virthba_driver);
/* unregister is going to call virthba_remove */ /* unregister is going to call virthba_remove */
/* destroy serverdown completion workqueue */ /* destroy serverdown completion workqueue */
...@@ -1691,7 +1638,6 @@ virthba_mod_exit(void) ...@@ -1691,7 +1638,6 @@ virthba_mod_exit(void)
} }
debugfs_remove_recursive(virthba_debugfs_dir); debugfs_remove_recursive(virthba_debugfs_dir);
LOGINF("Leaving virthba_mod_exit\n");
} }
/* specify function to be run at module insertion time */ /* specify function to be run at module insertion time */
......
...@@ -279,8 +279,6 @@ static int add_vbus(struct add_vbus_guestpart *addparams) ...@@ -279,8 +279,6 @@ static int add_vbus(struct add_vbus_guestpart *addparams)
&chipset_driver_info); &chipset_driver_info);
write_vbus_bus_info(vbus->platform_data /* chanptr */, write_vbus_bus_info(vbus->platform_data /* chanptr */,
&bus_driver_info); &bus_driver_info);
LOGINF("Added vbus %d; device %s created successfully\n",
addparams->bus_no, BUS_ID(vbus));
POSTCODE_LINUX_2(VPCI_CREATE_EXIT_PC, POSTCODE_SEVERITY_INFO); POSTCODE_LINUX_2(VPCI_CREATE_EXIT_PC, POSTCODE_SEVERITY_INFO);
return 1; return 1;
} }
...@@ -328,14 +326,8 @@ static int add_vhba(struct add_virt_guestpart *addparams) ...@@ -328,14 +326,8 @@ static int add_vhba(struct add_virt_guestpart *addparams)
return 0; return 0;
} }
LOGINF("Adding vhba wwnn:%x:%x config:%d-%d-%d-%d chanptr:%p\n",
scsi.wwnn.wwnn1, scsi.wwnn.wwnn2,
scsi.max.max_channel, scsi.max.max_id, scsi.max.max_lun,
scsi.max.cmd_per_lun, addparams->chanptr);
i = virtpci_device_add(vbus, VIRTHBA_TYPE, addparams, &scsi, NULL); i = virtpci_device_add(vbus, VIRTHBA_TYPE, addparams, &scsi, NULL);
if (i) { if (i) {
LOGINF("Added vhba wwnn:%x:%x chanptr:%p\n", scsi.wwnn.wwnn1,
scsi.wwnn.wwnn2, addparams->chanptr);
POSTCODE_LINUX_3(VPCI_CREATE_EXIT_PC, i, POSTCODE_LINUX_3(VPCI_CREATE_EXIT_PC, i,
POSTCODE_SEVERITY_INFO); POSTCODE_SEVERITY_INFO);
} }
...@@ -391,15 +383,8 @@ add_vnic(struct add_virt_guestpart *addparams) ...@@ -391,15 +383,8 @@ add_vnic(struct add_virt_guestpart *addparams)
return 0; return 0;
} }
LOGINF("Adding vnic macaddr:%02x:%02x:%02x:%02x:%02x:%02x rcvbufs:%d mtu:%d chanptr:%p%pUL\n",
net.mac_addr[0], net.mac_addr[1], net.mac_addr[2],
net.mac_addr[3], net.mac_addr[4], net.mac_addr[5],
net.num_rcv_bufs, net.mtu, addparams->chanptr, &net.zone_uuid);
i = virtpci_device_add(vbus, VIRTNIC_TYPE, addparams, NULL, &net); i = virtpci_device_add(vbus, VIRTNIC_TYPE, addparams, NULL, &net);
if (i) { if (i) {
LOGINF("Added vnic macaddr:%02x:%02x:%02x:%02x:%02x:%02x\n",
net.mac_addr[0], net.mac_addr[1], net.mac_addr[2],
net.mac_addr[3], net.mac_addr[4], net.mac_addr[5]);
POSTCODE_LINUX_3(VPCI_CREATE_EXIT_PC, i, POSTCODE_LINUX_3(VPCI_CREATE_EXIT_PC, i,
POSTCODE_SEVERITY_INFO); POSTCODE_SEVERITY_INFO);
return 1; return 1;
...@@ -426,10 +411,6 @@ delete_vbus(struct del_vbus_guestpart *delparams) ...@@ -426,10 +411,6 @@ delete_vbus(struct del_vbus_guestpart *delparams)
} }
/* ensure that bus has no devices? -- TBD */ /* ensure that bus has no devices? -- TBD */
LOGINF("Deleting %s\n", BUS_ID(vbus));
if (delete_vbus_device(vbus, NULL))
return 0; /* failure */
LOGINF("Deleted vbus %d\n", delparams->bus_no);
return 1; return 1;
} }
...@@ -441,13 +422,10 @@ delete_vbus_device(struct device *vbus, void *data) ...@@ -441,13 +422,10 @@ delete_vbus_device(struct device *vbus, void *data)
if ((checkforroot) && match_busid(vbus, (void *)BUS_ID(dev))) { if ((checkforroot) && match_busid(vbus, (void *)BUS_ID(dev))) {
/* skip it - don't delete root bus */ /* skip it - don't delete root bus */
LOGINF("skipping root bus\n");
return 0; /* pretend no error */ return 0; /* pretend no error */
} }
LOGINF("Calling unregister for %s\n", BUS_ID(vbus));
device_unregister(vbus); device_unregister(vbus);
kfree(vbus); kfree(vbus);
LOGINF("VBus unregister and freed\n");
return 0; /* no error */ return 0; /* no error */
} }
...@@ -461,12 +439,8 @@ static int pause_vhba(struct pause_virt_guestpart *pauseparams) ...@@ -461,12 +439,8 @@ static int pause_vhba(struct pause_virt_guestpart *pauseparams)
GET_SCSIADAPINFO_FROM_CHANPTR(pauseparams->chanptr); GET_SCSIADAPINFO_FROM_CHANPTR(pauseparams->chanptr);
LOGINF("Pausing vhba wwnn:%x:%x\n", scsi.wwnn.wwnn1, scsi.wwnn.wwnn2);
i = virtpci_device_serverdown(NULL /*no parent bus */, VIRTHBA_TYPE, i = virtpci_device_serverdown(NULL /*no parent bus */, VIRTHBA_TYPE,
&scsi.wwnn, NULL); &scsi.wwnn, NULL);
if (i)
LOGINF("Paused vhba wwnn:%x:%x\n", scsi.wwnn.wwnn1,
scsi.wwnn.wwnn2);
return i; return i;
} }
...@@ -480,16 +454,8 @@ static int pause_vnic(struct pause_virt_guestpart *pauseparams) ...@@ -480,16 +454,8 @@ static int pause_vnic(struct pause_virt_guestpart *pauseparams)
GET_NETADAPINFO_FROM_CHANPTR(pauseparams->chanptr); GET_NETADAPINFO_FROM_CHANPTR(pauseparams->chanptr);
LOGINF("Pausing vnic macaddr:%02x:%02x:%02x:%02x:%02x:%02x\n",
net.mac_addr[0], net.mac_addr[1], net.mac_addr[2],
net.mac_addr[3], net.mac_addr[4], net.mac_addr[5]);
i = virtpci_device_serverdown(NULL /*no parent bus */, VIRTNIC_TYPE, i = virtpci_device_serverdown(NULL /*no parent bus */, VIRTNIC_TYPE,
NULL, net.mac_addr); NULL, net.mac_addr);
if (i) {
LOGINF(" Paused vnic macaddr:%02x:%02x:%02x:%02x:%02x:%02x\n",
net.mac_addr[0], net.mac_addr[1], net.mac_addr[2],
net.mac_addr[3], net.mac_addr[4], net.mac_addr[5]);
}
return i; return i;
} }
...@@ -503,12 +469,8 @@ static int resume_vhba(struct resume_virt_guestpart *resumeparams) ...@@ -503,12 +469,8 @@ static int resume_vhba(struct resume_virt_guestpart *resumeparams)
GET_SCSIADAPINFO_FROM_CHANPTR(resumeparams->chanptr); GET_SCSIADAPINFO_FROM_CHANPTR(resumeparams->chanptr);
LOGINF("Resuming vhba wwnn:%x:%x\n", scsi.wwnn.wwnn1, scsi.wwnn.wwnn2);
i = virtpci_device_serverup(NULL /*no parent bus */, VIRTHBA_TYPE, i = virtpci_device_serverup(NULL /*no parent bus */, VIRTHBA_TYPE,
&scsi.wwnn, NULL); &scsi.wwnn, NULL);
if (i)
LOGINF("Resumed vhba wwnn:%x:%x\n", scsi.wwnn.wwnn1,
scsi.wwnn.wwnn2);
return i; return i;
} }
...@@ -523,16 +485,8 @@ resume_vnic(struct resume_virt_guestpart *resumeparams) ...@@ -523,16 +485,8 @@ resume_vnic(struct resume_virt_guestpart *resumeparams)
GET_NETADAPINFO_FROM_CHANPTR(resumeparams->chanptr); GET_NETADAPINFO_FROM_CHANPTR(resumeparams->chanptr);
LOGINF("Resuming vnic macaddr:%02x:%02x:%02x:%02x:%02x:%02x\n",
net.mac_addr[0], net.mac_addr[1], net.mac_addr[2],
net.mac_addr[3], net.mac_addr[4], net.mac_addr[5]);
i = virtpci_device_serverup(NULL /*no parent bus */, VIRTNIC_TYPE, i = virtpci_device_serverup(NULL /*no parent bus */, VIRTNIC_TYPE,
NULL, net.mac_addr); NULL, net.mac_addr);
if (i) {
LOGINF(" Resumed vnic macaddr:%02x:%02x:%02x:%02x:%02x:%02x\n",
net.mac_addr[0], net.mac_addr[1], net.mac_addr[2],
net.mac_addr[3], net.mac_addr[4], net.mac_addr[5]);
}
return i; return i;
} }
...@@ -546,12 +500,9 @@ static int delete_vhba(struct del_virt_guestpart *delparams) ...@@ -546,12 +500,9 @@ static int delete_vhba(struct del_virt_guestpart *delparams)
GET_SCSIADAPINFO_FROM_CHANPTR(delparams->chanptr); GET_SCSIADAPINFO_FROM_CHANPTR(delparams->chanptr);
LOGINF("Deleting vhba wwnn:%x:%x\n", scsi.wwnn.wwnn1, scsi.wwnn.wwnn2);
i = virtpci_device_del(NULL /*no parent bus */, VIRTHBA_TYPE, i = virtpci_device_del(NULL /*no parent bus */, VIRTHBA_TYPE,
&scsi.wwnn, NULL); &scsi.wwnn, NULL);
if (i) { if (i) {
LOGINF("Deleted vhba wwnn:%x:%x\n", scsi.wwnn.wwnn1,
scsi.wwnn.wwnn2);
return 1; return 1;
} }
return 0; return 0;
...@@ -567,23 +518,13 @@ static int delete_vnic(struct del_virt_guestpart *delparams) ...@@ -567,23 +518,13 @@ static int delete_vnic(struct del_virt_guestpart *delparams)
GET_NETADAPINFO_FROM_CHANPTR(delparams->chanptr); GET_NETADAPINFO_FROM_CHANPTR(delparams->chanptr);
LOGINF("Deleting vnic macaddr:%02x:%02x:%02x:%02x:%02x:%02x\n",
net.mac_addr[0], net.mac_addr[1], net.mac_addr[2],
net.mac_addr[3], net.mac_addr[4], net.mac_addr[5]);
i = virtpci_device_del(NULL /*no parent bus */, VIRTNIC_TYPE, NULL, i = virtpci_device_del(NULL /*no parent bus */, VIRTNIC_TYPE, NULL,
net.mac_addr); net.mac_addr);
if (i) {
LOGINF("Deleted vnic macaddr:%02x:%02x:%02x:%02x:%02x:%02x\n",
net.mac_addr[0], net.mac_addr[1], net.mac_addr[2],
net.mac_addr[3], net.mac_addr[4], net.mac_addr[5]);
}
return i; return i;
} }
#define DELETE_ONE_VPCIDEV(vpcidev) { \ #define DELETE_ONE_VPCIDEV(vpcidev) { \
LOGINF("calling device_unregister:%p\n", &vpcidev->generic_dev); \
device_unregister(&vpcidev->generic_dev); \ device_unregister(&vpcidev->generic_dev); \
LOGINF("Deleted %p\n", vpcidev); \
kfree(vpcidev); \ kfree(vpcidev); \
} }
...@@ -610,12 +551,10 @@ static void delete_all(void) ...@@ -610,12 +551,10 @@ static void delete_all(void)
tmpvpcidev = nextvpcidev; tmpvpcidev = nextvpcidev;
count++; count++;
} }
LOGINF("Deleted %d vhbas/vnics.\n", count);
/* now delete each vbus */ /* now delete each vbus */
if (bus_for_each_dev bus_for_each_dev(&virtpci_bus_type, NULL, (void *)1,
(&virtpci_bus_type, NULL, (void *)1, delete_vbus_device)) delete_vbus_device);
LOGERR("delete of all vbus failed\n");
} }
/* deletes all vnics or vhbas /* deletes all vnics or vhbas
...@@ -643,13 +582,8 @@ static int delete_all_virt(enum virtpci_dev_type devtype, ...@@ -643,13 +582,8 @@ static int delete_all_virt(enum virtpci_dev_type devtype,
return 0; return 0;
} }
LOGINF("Deleting all %s in vbus %s\n",
devtype == VIRTHBA_TYPE ? "vhbas" : "vnics", busid);
/* delete all vhbas/vnics */ /* delete all vhbas/vnics */
i = virtpci_device_del(vbus, devtype, NULL, NULL); i = virtpci_device_del(vbus, devtype, NULL, NULL);
if (i > 0)
LOGINF("Deleted %d %s\n", i,
devtype == VIRTHBA_TYPE ? "vhbas" : "vnics");
return 1; return 1;
} }
...@@ -812,8 +746,6 @@ static int virtpci_device_probe(struct device *dev) ...@@ -812,8 +746,6 @@ static int virtpci_device_probe(struct device *dev)
const struct pci_device_id *id; const struct pci_device_id *id;
int error = 0; int error = 0;
LOGINF("In virtpci_device_probe dev:%p virtpcidev:%p virtpcidrv:%p\n",
dev, virtpcidev, virtpcidrv); /* VERBOSE/DEBUG ? */
POSTCODE_LINUX_2(VPCI_PROBE_ENTRY_PC, POSTCODE_SEVERITY_INFO); POSTCODE_LINUX_2(VPCI_PROBE_ENTRY_PC, POSTCODE_SEVERITY_INFO);
/* static match and static probe vs dynamic match & dynamic /* static match and static probe vs dynamic match & dynamic
* probe - do we care?. * probe - do we care?.
...@@ -858,9 +790,6 @@ static int virtpci_device_remove(struct device *dev_) ...@@ -858,9 +790,6 @@ static int virtpci_device_remove(struct device *dev_)
struct virtpci_dev *virtpcidev = device_to_virtpci_dev(dev_); struct virtpci_dev *virtpcidev = device_to_virtpci_dev(dev_);
struct virtpci_driver *virtpcidrv = virtpcidev->mydriver; struct virtpci_driver *virtpcidrv = virtpcidev->mydriver;
LOGINF("In virtpci_device_remove bus_id:%s dev_:%p virtpcidev:%p dev->driver:%p drivername:%s\n",
BUS_ID(dev_), dev_, virtpcidev, dev_->driver,
dev_->driver->name); /* VERBOSE/DEBUG */
if (virtpcidrv) { if (virtpcidrv) {
/* TEMP: assuming we have only one such driver for now */ /* TEMP: assuming we have only one such driver for now */
if (virtpcidrv->remove) if (virtpcidrv->remove)
...@@ -899,9 +828,6 @@ static int virtpci_device_add(struct device *parentbus, int devtype, ...@@ -899,9 +828,6 @@ static int virtpci_device_add(struct device *parentbus, int devtype,
struct spar_io_channel_protocol __iomem *io_chan = NULL; struct spar_io_channel_protocol __iomem *io_chan = NULL;
struct device *dev; struct device *dev;
LOGINF("virtpci_device_add parentbus:%p chanptr:%p\n", parentbus,
addparams->chanptr);
POSTCODE_LINUX_2(VPCI_CREATE_ENTRY_PC, POSTCODE_SEVERITY_INFO); POSTCODE_LINUX_2(VPCI_CREATE_ENTRY_PC, POSTCODE_SEVERITY_INFO);
if ((devtype != VIRTHBA_TYPE) && (devtype != VIRTNIC_TYPE)) { if ((devtype != VIRTHBA_TYPE) && (devtype != VIRTNIC_TYPE)) {
...@@ -1041,10 +967,6 @@ static int virtpci_device_add(struct device *parentbus, int devtype, ...@@ -1041,10 +967,6 @@ static int virtpci_device_add(struct device *parentbus, int devtype,
return 0; return 0;
} }
LOGINF("Added %s:%d:%d &virtpcidev->generic_dev:%p\n",
(devtype == VIRTHBA_TYPE) ? "virthba" : "virtnic",
addparams->bus_no, addparams->device_no,
&virtpcidev->generic_dev);
POSTCODE_LINUX_2(VPCI_CREATE_EXIT_PC, POSTCODE_SEVERITY_INFO); POSTCODE_LINUX_2(VPCI_CREATE_EXIT_PC, POSTCODE_SEVERITY_INFO);
return 1; return 1;
} }
...@@ -1284,7 +1206,6 @@ static void virtpci_device_release(struct device *dev_) ...@@ -1284,7 +1206,6 @@ static void virtpci_device_release(struct device *dev_)
/* this function is called when the last reference to the /* this function is called when the last reference to the
* device is removed * device is removed
*/ */
LOGINF("In virtpci_device_release:%p - NOT YET IMPLEMENTED\n", dev_);
} }
/*****************************************************/ /*****************************************************/
...@@ -1507,21 +1428,16 @@ static int __init virtpci_mod_init(void) ...@@ -1507,21 +1428,16 @@ static int __init virtpci_mod_init(void)
return -1; return -1;
} }
LOGINF("successfully registered virtpci_ctrlchan_func (0x%p) as callback.\n",
(void *)&virtpci_ctrlchan_func);
/* create debugfs directory and info file inside. */ /* create debugfs directory and info file inside. */
virtpci_debugfs_dir = debugfs_create_dir("virtpci", NULL); virtpci_debugfs_dir = debugfs_create_dir("virtpci", NULL);
debugfs_create_file("info", S_IRUSR, virtpci_debugfs_dir, debugfs_create_file("info", S_IRUSR, virtpci_debugfs_dir,
NULL, &debugfs_info_fops); NULL, &debugfs_info_fops);
LOGINF("Leaving\n");
POSTCODE_LINUX_2(VPCI_CREATE_EXIT_PC, POSTCODE_SEVERITY_INFO); POSTCODE_LINUX_2(VPCI_CREATE_EXIT_PC, POSTCODE_SEVERITY_INFO);
return 0; return 0;
} }
static void __exit virtpci_mod_exit(void) static void __exit virtpci_mod_exit(void)
{ {
LOGINF("virtpci_mod_exit...\n");
/* unregister the callback function */ /* unregister the callback function */
if (!uisctrl_register_req_handler(2, NULL, NULL)) if (!uisctrl_register_req_handler(2, NULL, NULL))
LOGERR("uisctrl_register_req_handler ****FAILED.\n"); LOGERR("uisctrl_register_req_handler ****FAILED.\n");
...@@ -1529,7 +1445,6 @@ static void __exit virtpci_mod_exit(void) ...@@ -1529,7 +1445,6 @@ static void __exit virtpci_mod_exit(void)
device_unregister(&virtpci_rootbus_device); device_unregister(&virtpci_rootbus_device);
bus_unregister(&virtpci_bus_type); bus_unregister(&virtpci_bus_type);
debugfs_remove_recursive(virtpci_debugfs_dir); debugfs_remove_recursive(virtpci_debugfs_dir);
LOGINF("Leaving\n");
} }
module_init(virtpci_mod_init); module_init(virtpci_mod_init);
......
...@@ -32,14 +32,12 @@ visorchannel_init(void) ...@@ -32,14 +32,12 @@ visorchannel_init(void)
if (!unisys_spar_platform) if (!unisys_spar_platform)
return -ENODEV; return -ENODEV;
INFODRV("driver version %s loaded", VERSION);
return 0; return 0;
} }
static void static void
visorchannel_exit(void) visorchannel_exit(void)
{ {
INFODRV("driver unloaded");
} }
module_init(visorchannel_init); module_init(visorchannel_init);
......
...@@ -66,7 +66,6 @@ visorchipset_file_init(dev_t major_dev, struct visorchannel **controlvm_channel) ...@@ -66,7 +66,6 @@ visorchipset_file_init(dev_t major_dev, struct visorchannel **controlvm_channel)
return -1; return -1;
} }
registered = TRUE; registered = TRUE;
INFODRV("New major number %d registered\n", MAJOR(majordev));
} else { } else {
/* static major device number registration required */ /* static major device number registration required */
if (register_chrdev_region(majordev, 1, MYDRVNAME) < 0) { if (register_chrdev_region(majordev, 1, MYDRVNAME) < 0) {
...@@ -74,15 +73,12 @@ visorchipset_file_init(dev_t major_dev, struct visorchannel **controlvm_channel) ...@@ -74,15 +73,12 @@ visorchipset_file_init(dev_t major_dev, struct visorchannel **controlvm_channel)
return -1; return -1;
} }
registered = TRUE; registered = TRUE;
INFODRV("Static major number %d registered\n", MAJOR(majordev));
} }
rc = cdev_add(&file_cdev, MKDEV(MAJOR(majordev), 0), 1); rc = cdev_add(&file_cdev, MKDEV(MAJOR(majordev), 0), 1);
if (rc < 0) { if (rc < 0) {
ERRDRV("failed to create char device: (status=%d)\n", rc); ERRDRV("failed to create char device: (status=%d)\n", rc);
return -1; return -1;
} }
INFODRV("Registered char device for %s (major=%d)",
MYDRVNAME, MAJOR(majordev));
return 0; return 0;
} }
......
...@@ -712,11 +712,9 @@ controlvm_respond(struct controlvm_message_header *msgHdr, int response) ...@@ -712,11 +712,9 @@ controlvm_respond(struct controlvm_message_header *msgHdr, int response)
&& g_DeviceChangeStatePacket.device_change_state.dev_no == && g_DeviceChangeStatePacket.device_change_state.dev_no ==
g_diagpoolDevNo) g_diagpoolDevNo)
outmsg.cmd = g_DeviceChangeStatePacket; outmsg.cmd = g_DeviceChangeStatePacket;
if (outmsg.hdr.flags.test_message == 1) { if (outmsg.hdr.flags.test_message == 1)
LOGINF("%s controlvm_msg=0x%x response=%d for test message",
__func__, outmsg.hdr.id, response);
return; return;
}
if (!visorchannel_signalinsert(ControlVm_channel, if (!visorchannel_signalinsert(ControlVm_channel,
CONTROLVM_QUEUE_REQUEST, &outmsg)) { CONTROLVM_QUEUE_REQUEST, &outmsg)) {
LOGERR("signalinsert failed!"); LOGERR("signalinsert failed!");
...@@ -1063,8 +1061,6 @@ device_epilog(u32 busNo, u32 devNo, struct spar_segment_state state, u32 cmd, ...@@ -1063,8 +1061,6 @@ device_epilog(u32 busNo, u32 devNo, struct spar_segment_state state, u32 cmd,
*/ */
if (busNo == g_diagpoolBusNo if (busNo == g_diagpoolBusNo
&& devNo == g_diagpoolDevNo) { && devNo == g_diagpoolDevNo) {
LOGINF("DEVICE_CHANGESTATE(DiagpoolChannel busNo=%d devNo=%d is pausing...)",
busNo, devNo);
/* this will trigger the /* this will trigger the
* diag_shutdown.sh script in * diag_shutdown.sh script in
* the visorchipset hotplug */ * the visorchipset hotplug */
...@@ -1292,8 +1288,6 @@ my_device_create(struct controlvm_message *inmsg) ...@@ -1292,8 +1288,6 @@ my_device_create(struct controlvm_message *inmsg)
is_diagpool_channel(pDevInfo->chan_info.channel_type_uuid)) { is_diagpool_channel(pDevInfo->chan_info.channel_type_uuid)) {
g_diagpoolBusNo = busNo; g_diagpoolBusNo = busNo;
g_diagpoolDevNo = devNo; g_diagpoolDevNo = devNo;
LOGINF("CONTROLVM_DEVICE_CREATE for DiagPool channel: busNo=%lu, devNo=%lu",
g_diagpoolBusNo, g_diagpoolDevNo);
} }
device_epilog(busNo, devNo, segment_state_running, device_epilog(busNo, devNo, segment_state_running,
CONTROLVM_DEVICE_CREATE, &inmsg->hdr, rc, CONTROLVM_DEVICE_CREATE, &inmsg->hdr, rc,
...@@ -1404,8 +1398,6 @@ initialize_controlvm_payload_info(HOSTADDRESS phys_addr, u64 offset, u32 bytes, ...@@ -1404,8 +1398,6 @@ initialize_controlvm_payload_info(HOSTADDRESS phys_addr, u64 offset, u32 bytes,
info->offset = offset; info->offset = offset;
info->bytes = bytes; info->bytes = bytes;
info->ptr = payload; info->ptr = payload;
LOGINF("offset=%llu, bytes=%lu, ptr=%p",
(u64) (info->offset), (ulong) (info->bytes), info->ptr);
Away: Away:
if (rc < 0) { if (rc < 0) {
...@@ -1506,7 +1498,6 @@ chipset_ready(struct controlvm_message_header *msgHdr) ...@@ -1506,7 +1498,6 @@ chipset_ready(struct controlvm_message_header *msgHdr)
* and disks mounted for the partition * and disks mounted for the partition
*/ */
g_ChipSetMsgHdr = *msgHdr; g_ChipSetMsgHdr = *msgHdr;
LOGINF("Holding CHIPSET_READY response");
} }
} }
...@@ -1643,12 +1634,6 @@ parahotplug_request_kickoff(struct parahotplug_request *req) ...@@ -1643,12 +1634,6 @@ parahotplug_request_kickoff(struct parahotplug_request *req)
sprintf(env_func, "SPAR_PARAHOTPLUG_FUNCTION=%d", sprintf(env_func, "SPAR_PARAHOTPLUG_FUNCTION=%d",
cmd->device_change_state.dev_no & 0x7); cmd->device_change_state.dev_no & 0x7);
LOGINF("parahotplug_request_kickoff: state=%d, bdf=%d/%d/%d, id=%u\n",
cmd->device_change_state.state.active,
cmd->device_change_state.bus_no,
cmd->device_change_state.dev_no >> 3,
cmd->device_change_state.dev_no & 7, req->id);
kobject_uevent_env(&Visorchipset_platform_device.dev.kobj, KOBJ_CHANGE, kobject_uevent_env(&Visorchipset_platform_device.dev.kobj, KOBJ_CHANGE,
envp); envp);
} }
...@@ -1827,43 +1812,24 @@ handle_command(struct controlvm_message inmsg, HOSTADDRESS channel_addr) ...@@ -1827,43 +1812,24 @@ handle_command(struct controlvm_message inmsg, HOSTADDRESS channel_addr)
} }
switch (inmsg.hdr.id) { switch (inmsg.hdr.id) {
case CONTROLVM_CHIPSET_INIT: case CONTROLVM_CHIPSET_INIT:
LOGINF("CHIPSET_INIT(#busses=%lu,#switches=%lu)",
(ulong) inmsg.cmd.init_chipset.bus_count,
(ulong) inmsg.cmd.init_chipset.switch_count);
chipset_init(&inmsg); chipset_init(&inmsg);
break; break;
case CONTROLVM_BUS_CREATE: case CONTROLVM_BUS_CREATE:
LOGINF("BUS_CREATE(%lu,#devs=%lu)",
(ulong) cmd->create_bus.bus_no,
(ulong) cmd->create_bus.dev_count);
bus_create(&inmsg); bus_create(&inmsg);
break; break;
case CONTROLVM_BUS_DESTROY: case CONTROLVM_BUS_DESTROY:
LOGINF("BUS_DESTROY(%lu)", (ulong) cmd->destroy_bus.bus_no);
bus_destroy(&inmsg); bus_destroy(&inmsg);
break; break;
case CONTROLVM_BUS_CONFIGURE: case CONTROLVM_BUS_CONFIGURE:
LOGINF("BUS_CONFIGURE(%lu)", (ulong) cmd->configure_bus.bus_no);
bus_configure(&inmsg, parser_ctx); bus_configure(&inmsg, parser_ctx);
break; break;
case CONTROLVM_DEVICE_CREATE: case CONTROLVM_DEVICE_CREATE:
LOGINF("DEVICE_CREATE(%lu,%lu)",
(ulong) cmd->create_device.bus_no,
(ulong) cmd->create_device.dev_no);
my_device_create(&inmsg); my_device_create(&inmsg);
break; break;
case CONTROLVM_DEVICE_CHANGESTATE: case CONTROLVM_DEVICE_CHANGESTATE:
if (cmd->device_change_state.flags.phys_device) { if (cmd->device_change_state.flags.phys_device) {
LOGINF("DEVICE_CHANGESTATE for physical device (%lu,%lu, active=%lu)",
(ulong) cmd->device_change_state.bus_no,
(ulong) cmd->device_change_state.dev_no,
(ulong) cmd->device_change_state.state.active);
parahotplug_process_message(&inmsg); parahotplug_process_message(&inmsg);
} else { } else {
LOGINF("DEVICE_CHANGESTATE for virtual device (%lu,%lu, state.Alive=0x%lx)",
(ulong) cmd->device_change_state.bus_no,
(ulong) cmd->device_change_state.dev_no,
(ulong) cmd->device_change_state.state.alive);
/* save the hdr and cmd structures for later use */ /* save the hdr and cmd structures for later use */
/* when sending back the response to Command */ /* when sending back the response to Command */
my_device_changestate(&inmsg); my_device_changestate(&inmsg);
...@@ -1873,29 +1839,20 @@ handle_command(struct controlvm_message inmsg, HOSTADDRESS channel_addr) ...@@ -1873,29 +1839,20 @@ handle_command(struct controlvm_message inmsg, HOSTADDRESS channel_addr)
} }
break; break;
case CONTROLVM_DEVICE_DESTROY: case CONTROLVM_DEVICE_DESTROY:
LOGINF("DEVICE_DESTROY(%lu,%lu)",
(ulong) cmd->destroy_device.bus_no,
(ulong) cmd->destroy_device.dev_no);
my_device_destroy(&inmsg); my_device_destroy(&inmsg);
break; break;
case CONTROLVM_DEVICE_CONFIGURE: case CONTROLVM_DEVICE_CONFIGURE:
LOGINF("DEVICE_CONFIGURE(%lu,%lu)",
(ulong) cmd->configure_device.bus_no,
(ulong) cmd->configure_device.dev_no);
/* no op for now, just send a respond that we passed */ /* no op for now, just send a respond that we passed */
if (inmsg.hdr.flags.response_expected) if (inmsg.hdr.flags.response_expected)
controlvm_respond(&inmsg.hdr, CONTROLVM_RESP_SUCCESS); controlvm_respond(&inmsg.hdr, CONTROLVM_RESP_SUCCESS);
break; break;
case CONTROLVM_CHIPSET_READY: case CONTROLVM_CHIPSET_READY:
LOGINF("CHIPSET_READY");
chipset_ready(&inmsg.hdr); chipset_ready(&inmsg.hdr);
break; break;
case CONTROLVM_CHIPSET_SELFTEST: case CONTROLVM_CHIPSET_SELFTEST:
LOGINF("CHIPSET_SELFTEST");
chipset_selftest(&inmsg.hdr); chipset_selftest(&inmsg.hdr);
break; break;
case CONTROLVM_CHIPSET_STOP: case CONTROLVM_CHIPSET_STOP:
LOGINF("CHIPSET_STOP");
chipset_notready(&inmsg.hdr); chipset_notready(&inmsg.hdr);
break; break;
default: default:
...@@ -1923,7 +1880,6 @@ static HOSTADDRESS controlvm_get_channel_address(void) ...@@ -1923,7 +1880,6 @@ static HOSTADDRESS controlvm_get_channel_address(void)
__func__); __func__);
return 0; return 0;
} }
INFODRV("controlvm addr=%Lx", addr);
return addr; return addr;
} }
...@@ -1956,7 +1912,6 @@ controlvm_periodic_work(struct work_struct *work) ...@@ -1956,7 +1912,6 @@ controlvm_periodic_work(struct work_struct *work)
if (visorchipset_holdchipsetready if (visorchipset_holdchipsetready
&& (g_ChipSetMsgHdr.id != CONTROLVM_INVALID)) { && (g_ChipSetMsgHdr.id != CONTROLVM_INVALID)) {
if (check_chipset_events() == 1) { if (check_chipset_events() == 1) {
LOGINF("Sending CHIPSET_READY response");
controlvm_respond(&g_ChipSetMsgHdr, 0); controlvm_respond(&g_ChipSetMsgHdr, 0);
clear_chipset_events(); clear_chipset_events();
memset(&g_ChipSetMsgHdr, 0, memset(&g_ChipSetMsgHdr, 0,
...@@ -2019,13 +1974,11 @@ controlvm_periodic_work(struct work_struct *work) ...@@ -2019,13 +1974,11 @@ controlvm_periodic_work(struct work_struct *work)
* polling * polling
*/ */
if (Poll_jiffies != POLLJIFFIES_CONTROLVMCHANNEL_SLOW) { if (Poll_jiffies != POLLJIFFIES_CONTROLVMCHANNEL_SLOW) {
LOGINF("switched to slow controlvm polling");
Poll_jiffies = POLLJIFFIES_CONTROLVMCHANNEL_SLOW; Poll_jiffies = POLLJIFFIES_CONTROLVMCHANNEL_SLOW;
} }
} else { } else {
if (Poll_jiffies != POLLJIFFIES_CONTROLVMCHANNEL_FAST) { if (Poll_jiffies != POLLJIFFIES_CONTROLVMCHANNEL_FAST) {
Poll_jiffies = POLLJIFFIES_CONTROLVMCHANNEL_FAST; Poll_jiffies = POLLJIFFIES_CONTROLVMCHANNEL_FAST;
LOGINF("switched to fast controlvm polling");
} }
} }
...@@ -2135,7 +2088,6 @@ setup_crash_devices_work_queue(struct work_struct *work) ...@@ -2135,7 +2088,6 @@ setup_crash_devices_work_queue(struct work_struct *work)
POSTCODE_SEVERITY_ERR); POSTCODE_SEVERITY_ERR);
return; return;
} }
LOGINF("Bus and device ready for dumping");
POSTCODE_LINUX_2(CRASH_DEV_EXIT_PC, POSTCODE_SEVERITY_INFO); POSTCODE_LINUX_2(CRASH_DEV_EXIT_PC, POSTCODE_SEVERITY_INFO);
return; return;
...@@ -2344,25 +2296,11 @@ static int __init ...@@ -2344,25 +2296,11 @@ static int __init
visorchipset_init(void) visorchipset_init(void)
{ {
int rc = 0, x = 0; int rc = 0, x = 0;
char s[64];
HOSTADDRESS addr; HOSTADDRESS addr;
if (!unisys_spar_platform) if (!unisys_spar_platform)
return -ENODEV; return -ENODEV;
LOGINF("chipset driver version %s loaded", VERSION);
/* process module options */
POSTCODE_LINUX_2(DRIVER_ENTRY_PC, POSTCODE_SEVERITY_INFO);
LOGINF("option - testvnic=%d", visorchipset_testvnic);
LOGINF("option - testvnicclient=%d", visorchipset_testvnicclient);
LOGINF("option - testmsg=%d", visorchipset_testmsg);
LOGINF("option - testteardown=%d", visorchipset_testteardown);
LOGINF("option - major=%d", visorchipset_major);
LOGINF("option - serverregwait=%d", visorchipset_serverregwait);
LOGINF("option - clientregwait=%d", visorchipset_clientregwait);
LOGINF("option - holdchipsetready=%d", visorchipset_holdchipsetready);
memset(&BusDev_Server_Notifiers, 0, sizeof(BusDev_Server_Notifiers)); memset(&BusDev_Server_Notifiers, 0, sizeof(BusDev_Server_Notifiers));
memset(&BusDev_Client_Notifiers, 0, sizeof(BusDev_Client_Notifiers)); memset(&BusDev_Client_Notifiers, 0, sizeof(BusDev_Client_Notifiers));
memset(&ControlVm_payload_info, 0, sizeof(ControlVm_payload_info)); memset(&ControlVm_payload_info, 0, sizeof(ControlVm_payload_info));
...@@ -2386,8 +2324,6 @@ visorchipset_init(void) ...@@ -2386,8 +2324,6 @@ visorchipset_init(void)
spar_controlvm_channel_protocol_uuid); spar_controlvm_channel_protocol_uuid);
if (SPAR_CONTROLVM_CHANNEL_OK_CLIENT( if (SPAR_CONTROLVM_CHANNEL_OK_CLIENT(
visorchannel_get_header(ControlVm_channel))) { visorchannel_get_header(ControlVm_channel))) {
LOGINF("Channel %s (ControlVm) discovered",
visorchannel_id(ControlVm_channel, s));
initialize_controlvm_payload(); initialize_controlvm_payload();
} else { } else {
LOGERR("controlvm channel is invalid"); LOGERR("controlvm channel is invalid");
...@@ -2424,9 +2360,7 @@ visorchipset_init(void) ...@@ -2424,9 +2360,7 @@ visorchipset_init(void)
rc = -1; rc = -1;
goto Away; goto Away;
} }
if (visorchipset_disable_controlvm) { if (!visorchipset_disable_controlvm) {
LOGINF("visorchipset_init:controlvm disabled");
} else {
/* if booting in a crash kernel */ /* if booting in a crash kernel */
if (visorchipset_crash_kernel) if (visorchipset_crash_kernel)
INIT_DELAYED_WORK(&Periodic_controlvm_work, INIT_DELAYED_WORK(&Periodic_controlvm_work,
...@@ -2465,7 +2399,6 @@ visorchipset_init(void) ...@@ -2465,7 +2399,6 @@ visorchipset_init(void)
rc = -1; rc = -1;
goto Away; goto Away;
} }
LOGINF("visorchipset device created");
POSTCODE_LINUX_2(CHIPSET_INIT_SUCCESS_PC, POSTCODE_SEVERITY_INFO); POSTCODE_LINUX_2(CHIPSET_INIT_SUCCESS_PC, POSTCODE_SEVERITY_INFO);
rc = 0; rc = 0;
Away: Away:
...@@ -2480,8 +2413,6 @@ visorchipset_init(void) ...@@ -2480,8 +2413,6 @@ visorchipset_init(void)
static void static void
visorchipset_exit(void) visorchipset_exit(void)
{ {
char s[99];
POSTCODE_LINUX_2(DRIVER_EXIT_PC, POSTCODE_SEVERITY_INFO); POSTCODE_LINUX_2(DRIVER_EXIT_PC, POSTCODE_SEVERITY_INFO);
if (visorchipset_disable_controlvm) { if (visorchipset_disable_controlvm) {
...@@ -2507,13 +2438,10 @@ visorchipset_exit(void) ...@@ -2507,13 +2438,10 @@ visorchipset_exit(void)
memset(&g_DelDumpMsgHdr, 0, sizeof(struct controlvm_message_header)); memset(&g_DelDumpMsgHdr, 0, sizeof(struct controlvm_message_header));
LOGINF("Channel %s (ControlVm) disconnected",
visorchannel_id(ControlVm_channel, s));
visorchannel_destroy(ControlVm_channel); visorchannel_destroy(ControlVm_channel);
visorchipset_file_cleanup(); visorchipset_file_cleanup();
POSTCODE_LINUX_2(DRIVER_EXIT_PC, POSTCODE_SEVERITY_INFO); POSTCODE_LINUX_2(DRIVER_EXIT_PC, POSTCODE_SEVERITY_INFO);
LOGINF("chipset driver unloaded");
} }
module_param_named(testvnic, visorchipset_testvnic, int, S_IRUGO); module_param_named(testvnic, visorchipset_testvnic, int, S_IRUGO);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment