Support newer wil6210 driver in send_addba
In newer wil6210 driver, the debugfs file "vrings" was
renamed to "rings" as part of supporting a new chip.
Signed-off-by: Alexei Avshalom Lazar <ailizaro@codeaurora.org>
diff --git a/sta.c b/sta.c
index 26d0c34..f943a87 100644
--- a/sta.c
+++ b/sta.c
@@ -7316,10 +7316,18 @@
f = fopen(buf, "r");
if (!f) {
sigma_dut_print(dut, DUT_MSG_ERROR, "failed to open: %s", buf);
- return -1;
+ /* newer wil6210 driver renamed file to "rings" */
+ snprintf(buf, sizeof(buf), "%s/rings", dir);
+ f = fopen(buf, "r");
+ if (!f) {
+ sigma_dut_print(dut, DUT_MSG_ERROR,
+ "failed to open: %s", buf);
+ return -1;
+ }
}
- if (regcomp(&re, "VRING tx_[ \t]*([0-9]+)", REG_EXTENDED)) {
+ /* can be either VRING tx... or RING... */
+ if (regcomp(&re, "RING tx_[ \t]*([0-9]+)", REG_EXTENDED)) {
sigma_dut_print(dut, DUT_MSG_ERROR, "regcomp failed");
goto out;
}