• Sean Anderson's avatar
    net: fman: Map the base address once · 262f2b78
    Sean Anderson authored
    We don't need to remap the base address from the resource twice (once in
    mac_probe() and again in set_fman_mac_params()). We still need the
    resource to get the end address, but we can use a single function call
    to get both at once.
    
    While we're at it, use platform_get_mem_or_io and devm_request_resource
    to map the resource. I think this is the more "correct" way to do things
    here, since we use the pdev resource, instead of creating a new one.
    It's still a bit tricky, since we need to ensure that the resource is a
    child of the fman region when it gets requested.
    Signed-off-by: default avatarSean Anderson <sean.anderson@seco.com>
    Acked-by: default avatarCamelia Groza <camelia.groza@nxp.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    262f2b78
mac.h 2.15 KB