net: ipa: kill ipa_table_valid()
authorAlex Elder <elder@linaro.org>
Fri, 21 Oct 2022 19:13:39 +0000 (14:13 -0500)
committerPaolo Abeni <pabeni@redhat.com>
Tue, 25 Oct 2022 09:15:19 +0000 (11:15 +0200)
commit39ad815244ac3746c0194ae3eb45cb1f51d3489a
treeb528e63d648d39f39b1f633fecdf302d20c61904
parent7fd10a2aca6a2ff3316fac7fb2a72f6e1b303a57
net: ipa: kill ipa_table_valid()

What ipa_table_valid() (and ipa_table_valid_one(), which it calls)
does is ensure that the memory regions that hold routing and filter
tables have reasonable size.  Specifically, it checks that the size
of a region is sufficient (or rather, exactly the right size) to
hold the maximum number of entries supported by the driver.  (There
is an additional check that's erroneous, but in practice it is never
reached.)

Recently ipa_table_mem_valid() was added, which is called by
ipa_table_init().  That function verifies that all table memory
regions are of sufficient size, and requires hashed tables to have
zero size if hashing is not supported.  It only ensures the filter
table is large enough to hold the number of endpoints that support
filtering, but that is adequate.

Therefore everything that ipa_table_valid() does is redundant, so
get rid of it.

Signed-off-by: Alex Elder <elder@linaro.org>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
drivers/net/ipa/ipa_mem.c
drivers/net/ipa/ipa_table.c
drivers/net/ipa/ipa_table.h