Skip to content

Commit

Permalink
net: ipa: kill ipa_version_supported()
Browse files Browse the repository at this point in the history
The only place ipa_version_supported() is called is in the probe
function.  The version comes from the match data.  Rather than
checking the version validity separately, just consider anything
that has match data to be supported.

Signed-off-by: Alex Elder <elder@linaro.org>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
  • Loading branch information
Alex Elder authored and Paolo Abeni committed Apr 23, 2024
1 parent 319b6d4 commit dfdd70e
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 23 deletions.
5 changes: 0 additions & 5 deletions drivers/net/ipa/ipa_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -810,11 +810,6 @@ static int ipa_probe(struct platform_device *pdev)
return -ENODEV;
}

if (!ipa_version_supported(data->version)) {
dev_err(dev, "unsupported IPA version %u\n", data->version);
return -EINVAL;
}

if (!data->modem_route_count) {
dev_err(dev, "modem_route_count cannot be zero\n");
return -EINVAL;
Expand Down
18 changes: 0 additions & 18 deletions drivers/net/ipa/ipa_version.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,24 +47,6 @@ enum ipa_version {
IPA_VERSION_COUNT, /* Last; not a version */
};

static inline bool ipa_version_supported(enum ipa_version version)
{
switch (version) {
case IPA_VERSION_3_1:
case IPA_VERSION_3_5_1:
case IPA_VERSION_4_2:
case IPA_VERSION_4_5:
case IPA_VERSION_4_7:
case IPA_VERSION_4_9:
case IPA_VERSION_4_11:
case IPA_VERSION_5_0:
case IPA_VERSION_5_5:
return true;
default:
return false;
}
}

/* Execution environment IDs */
enum gsi_ee_id {
GSI_EE_AP = 0x0,
Expand Down

0 comments on commit dfdd70e

Please sign in to comment.