• Alan Tull's avatar
    fpga: bridge: change api, don't use drvdata · 371cd1b1
    Alan Tull authored
    Change fpga_bridge_register to not set drvdata.  This is to support
    the case where a PCIe device can have more than one bridge.
    
    Add API functions to create/free the fpga bridge struct. Change
    fpga_bridge_register/unregister to take FPGA bridge struct as
    the only parameter.
    
      struct fpga_bridge
      *fpga_bridge_create(struct device *dev, const char *name,
                          const struct fpga_bridge_ops *br_ops,
                          void *priv);
      void fpga_bridge_free(struct fpga_bridge *br);
      int fpga_bridge_register(struct fpga_bridge *br);
      void fpga_bridge_unregister(struct fpga_bridge *br);
    
    Update the drivers that call fpga_bridge_register with the new API.
    Signed-off-by: default avatarAlan Tull <atull@kernel.org>
    Reported-by: default avatarJiuyue Ma <majiuyue@huawei.com>
    Signed-off-by: default avatarMoritz Fischer <mdf@kernel.org>
    Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
    371cd1b1
xilinx-pr-decoupler.c 4.06 KB