Thread (20 messages) 20 messages, 3 authors, 2013-12-12

[net-next 11/15] i40e: debugfs command to change RSS queue count

flat view
STALE4694d SUPERSEDED: 1 (0M)

From: Jeff Kirsher <hidden>
Date: 2013-12-12 12:41:05
Subsystem: intel ethernet drivers, networking drivers, the rest · Maintainers: Tony Nguyen, Przemek Kitszel, Andrew Lunn, "David S. Miller", Eric Dumazet, Jakub Kicinski, Paolo Abeni, Linus Torvalds

Revision v1 of 102 in this series; 1 review trailer.

Revisions (102)
  1. v1
  2. v2 [diff vs current]
  3. v1
  4. v1
  5. v1
  6. v1
  7. v1
  8. v1
  9. v1
  10. v1
  11. v2 [diff vs current]
  12. v1
  13. v1
  14. v2 [diff vs current]
  15. v2 [diff vs current]
  16. v1
  17. v1
  18. v1
  19. v1
  20. v1
  21. v1
  22. v1
  23. v1
  24. v1
  25. v1
  26. v1
  27. v1
  28. v1
  29. v1
  30. v1
  31. v1
  32. v2 [diff vs current]
  33. v1
  34. v1
  35. v1
  36. v2 [diff vs current]
  37. v1
  38. v2 [diff vs current]
  39. v1
  40. v1
  41. v1
  42. v1
  43. v1
  44. v1
  45. v1
  46. v1
  47. v2 [diff vs current]
  48. v1
  49. v1
  50. v1
  51. v2 [diff vs current]
  52. v1
  53. v2 [diff vs current]
  54. v1
  55. v1
  56. v2 [diff vs current]
  57. v1
  58. v1
  59. v1
  60. v1
  61. v1
  62. v1 current
  63. v2 [diff vs current]
  64. v1
  65. v1
  66. v2 [diff vs current]
  67. v3 [diff vs current]
  68. v4 [diff vs current]
  69. v2 [diff vs current]
  70. v5 [diff vs current]
  71. v1
  72. v1
  73. v1
  74. v2 [diff vs current]
  75. v1
  76. v1
  77. v2 [diff vs current]
  78. v3 [diff vs current]
  79. v1
  80. v2 [diff vs current]
  81. v1
  82. v1
  83. v1
  84. v2 [diff vs current]
  85. v1
  86. v2 [diff vs current]
  87. v3 [diff vs current]
  88. v1
  89. v1
  90. v1
  91. v2 [diff vs current]
  92. v1
  93. v1
  94. v1
  95. v1
  96. v1
  97. v2 [diff vs current]
  98. v1
  99. v1
  100. v1
  101. v1
  102. v1
From: Anjali Singhai Jain <redacted>

This is the 3rd of 3 patches that implements changing the number
of queues on the fly.

This patch adds the debugfs hook for calling the change queues
flow with a request to change the number of RSS queues.

This is intended to also be called eventually from ethtool.

Change-Id: Ib6b332f0ec8e58989ef8c65ec30079d01fdf6c9a
Signed-off-by: Anjali Singhai Jain <redacted>
Signed-off-by: Jesse Brandeburg <redacted>
Tested-by: Kavindya Deegala <redacted>
Signed-off-by: Jeff Kirsher <redacted>
---
 drivers/net/ethernet/intel/i40e/i40e_debugfs.c | 12 ++++++++++++
 1 file changed, 12 insertions(+)
diff --git a/drivers/net/ethernet/intel/i40e/i40e_debugfs.c b/drivers/net/ethernet/intel/i40e/i40e_debugfs.c
index 9c675b5..3303b43 100644
--- a/drivers/net/ethernet/intel/i40e/i40e_debugfs.c
+++ b/drivers/net/ethernet/intel/i40e/i40e_debugfs.c
@@ -1792,6 +1792,17 @@ static ssize_t i40e_dbg_command_write(struct file *filp,
 		}
 		kfree(buff);
 		buff = NULL;
+	} else if (strncmp(cmd_buf, "set rss_size", 12) == 0) {
+		u16 queue_count;
+		cnt = sscanf(&cmd_buf[12], "%hi", &queue_count);
+		if (cnt != 1) {
+			dev_info(&pf->pdev->dev,
+				 "set rss_size: bad command string, cnt=%d\n", cnt);
+			goto command_write_done;
+		}
+		dev_info(&pf->pdev->dev, " set rss_size requesting %d queues\n", queue_count);
+		i40e_reconfig_rss_queues(pf, queue_count);
+		dev_info(&pf->pdev->dev, " new rss_size %d\n", pf->rss_size);
 	} else {
 		dev_info(&pf->pdev->dev, "unknown command '%s'\n", cmd_buf);
 		dev_info(&pf->pdev->dev, "available commands\n");
@@ -1827,6 +1838,7 @@ static ssize_t i40e_dbg_command_write(struct file *filp,
 		dev_info(&pf->pdev->dev, "  lldp event on\n");
 		dev_info(&pf->pdev->dev, "  lldp event off\n");
 		dev_info(&pf->pdev->dev, "  nvm read [module] [word_offset] [word_count]\n");
+		dev_info(&pf->pdev->dev, "  set rss_size <count>\n");
 	}
 
 command_write_done:
-- 
1.8.3.1
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help