Re: [EXT] Re: [PATCH v2 net-next 15/17] net: atlantic: common functions needed for basic A2 init/deinit hw_ops
From: Igor Russkikh <hidden>
Date: 2020-05-01 20:39:21
From: Igor Russkikh <hidden>
Date: 2020-05-01 20:39:21
On Thu, 30 Apr 2020 11:04:43 +0300 Igor Russkikh wrote:quoted
+ if (hw_atl_utils_ver_match(HW_ATL2_FW_VER_1X, + self->fw_ver_actual) == 0) { + *fw_ops = &aq_a2_fw_ops; + } else { + aq_pr_err("Bad FW version detected: %x, but continue\n", + self->fw_ver_actual); + *fw_ops = &aq_a2_fw_ops; + }nit: I assume that setting fw_ops to the same value is intentional here. FWIW it seems more readable when dealing with multiple versions of things to use switch statements, and the default clause.
Yes, thats intentional as we assume future FW versions will be backward compatible.
Series looks good to me otherwise.
Thanks for the review, Jakub! Igor