Commit 28c3948a authored by Sean Anderson's avatar Sean Anderson Committed by Jakub Kicinski

net: fman: Store initialization function in match data

Instead of re-matching the compatible string in order to determine the init
function, just store it in the match data. The separate setup functions
aren't needed anymore. Merge their content into init as well. To ensure
everything compiles correctly, we move them to the bottom of the file.
Signed-off-by: default avatarSean Anderson <sean.anderson@seco.com>
Acked-by: default avatarCamelia Groza <camelia.groza@nxp.com>
Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent 478eb957
This diff is collapsed.
...@@ -35,7 +35,6 @@ struct mac_device { ...@@ -35,7 +35,6 @@ struct mac_device {
bool promisc; bool promisc;
bool allmulti; bool allmulti;
int (*init)(struct mac_device *mac_dev, struct device_node *mac_node);
int (*enable)(struct fman_mac *mac_dev); int (*enable)(struct fman_mac *mac_dev);
int (*disable)(struct fman_mac *mac_dev); int (*disable)(struct fman_mac *mac_dev);
void (*adjust_link)(struct mac_device *mac_dev); void (*adjust_link)(struct mac_device *mac_dev);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment