Thread (26 messages) flat view 26 messages, 4 authors, 2016-08-22

RE: [PATCH net-next V3 11/18] liquidio: link and control commands

From: Yuval Mintz <hidden>
Date: 2016-08-22 16:15:57

+static inline void setup_link_status_change_wq(struct net_device *netdev)
+{
+	struct lio *lio = GET_LIO(netdev);
+	struct octeon_device *oct = lio->oct_dev;
+
+	lio->link_status_wq.wq = alloc_workqueue("link-status",
+						 WQ_MEM_RECLAIM, 0);
+	if (!lio->link_status_wq.wq) {
+		dev_err(&oct->pci_dev->dev, "unable to create cavium link
status wq\n");
+		return;
+	}
+	INIT_DELAYED_WORK(&lio->link_status_wq.wk.work,
+			  octnet_link_status_change);
+	lio->link_status_wq.wk.ctxptr = lio;
+}
Don't you need to propagate the allocation failure?
Won't this wouldn't you still try to schedule the non-initialized workitem
on the non-existent workqueue later on?
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help