aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/ipath/ipath_driver.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/infiniband/hw/ipath/ipath_driver.c')
-rw-r--r--drivers/infiniband/hw/ipath/ipath_driver.c20
1 files changed, 11 insertions, 9 deletions
diff --git a/drivers/infiniband/hw/ipath/ipath_driver.c b/drivers/infiniband/hw/ipath/ipath_driver.c
index ce7b7c34360e..daad09a45910 100644
--- a/drivers/infiniband/hw/ipath/ipath_driver.c
+++ b/drivers/infiniband/hw/ipath/ipath_driver.c
@@ -1894,7 +1894,7 @@ void ipath_cancel_sends(struct ipath_devdata *dd, int restore_sendctrl)
1894 */ 1894 */
1895 if (dd->ipath_flags & IPATH_HAS_SEND_DMA) { 1895 if (dd->ipath_flags & IPATH_HAS_SEND_DMA) {
1896 int skip_cancel; 1896 int skip_cancel;
1897 u64 *statp = &dd->ipath_sdma_status; 1897 unsigned long *statp = &dd->ipath_sdma_status;
1898 1898
1899 spin_lock_irqsave(&dd->ipath_sdma_lock, flags); 1899 spin_lock_irqsave(&dd->ipath_sdma_lock, flags);
1900 skip_cancel = 1900 skip_cancel =
@@ -2616,7 +2616,7 @@ int ipath_reset_device(int unit)
2616 ipath_dbg("unit %u port %d is in use " 2616 ipath_dbg("unit %u port %d is in use "
2617 "(PID %u cmd %s), can't reset\n", 2617 "(PID %u cmd %s), can't reset\n",
2618 unit, i, 2618 unit, i,
2619 dd->ipath_pd[i]->port_pid, 2619 pid_nr(dd->ipath_pd[i]->port_pid),
2620 dd->ipath_pd[i]->port_comm); 2620 dd->ipath_pd[i]->port_comm);
2621 ret = -EBUSY; 2621 ret = -EBUSY;
2622 goto bail; 2622 goto bail;
@@ -2654,19 +2654,21 @@ bail:
2654static int ipath_signal_procs(struct ipath_devdata *dd, int sig) 2654static int ipath_signal_procs(struct ipath_devdata *dd, int sig)
2655{ 2655{
2656 int i, sub, any = 0; 2656 int i, sub, any = 0;
2657 pid_t pid; 2657 struct pid *pid;
2658 2658
2659 if (!dd->ipath_pd) 2659 if (!dd->ipath_pd)
2660 return 0; 2660 return 0;
2661 for (i = 1; i < dd->ipath_cfgports; i++) { 2661 for (i = 1; i < dd->ipath_cfgports; i++) {
2662 if (!dd->ipath_pd[i] || !dd->ipath_pd[i]->port_cnt || 2662 if (!dd->ipath_pd[i] || !dd->ipath_pd[i]->port_cnt)
2663 !dd->ipath_pd[i]->port_pid)
2664 continue; 2663 continue;
2665 pid = dd->ipath_pd[i]->port_pid; 2664 pid = dd->ipath_pd[i]->port_pid;
2665 if (!pid)
2666 continue;
2667
2666 dev_info(&dd->pcidev->dev, "context %d in use " 2668 dev_info(&dd->pcidev->dev, "context %d in use "
2667 "(PID %u), sending signal %d\n", 2669 "(PID %u), sending signal %d\n",
2668 i, pid, sig); 2670 i, pid_nr(pid), sig);
2669 kill_proc(pid, sig, 1); 2671 kill_pid(pid, sig, 1);
2670 any++; 2672 any++;
2671 for (sub = 0; sub < INFINIPATH_MAX_SUBPORT; sub++) { 2673 for (sub = 0; sub < INFINIPATH_MAX_SUBPORT; sub++) {
2672 pid = dd->ipath_pd[i]->port_subpid[sub]; 2674 pid = dd->ipath_pd[i]->port_subpid[sub];
@@ -2674,8 +2676,8 @@ static int ipath_signal_procs(struct ipath_devdata *dd, int sig)
2674 continue; 2676 continue;
2675 dev_info(&dd->pcidev->dev, "sub-context " 2677 dev_info(&dd->pcidev->dev, "sub-context "
2676 "%d:%d in use (PID %u), sending " 2678 "%d:%d in use (PID %u), sending "
2677 "signal %d\n", i, sub, pid, sig); 2679 "signal %d\n", i, sub, pid_nr(pid), sig);
2678 kill_proc(pid, sig, 1); 2680 kill_pid(pid, sig, 1);
2679 any++; 2681 any++;
2680 } 2682 }
2681 } 2683 }