Skip to content

Commit

Permalink
fpga manager: remove label
Browse files Browse the repository at this point in the history
Remove implementation of 'label' DT binding.

Signed-off-by: Alan Tull <atull@opensource.altera.com>
Reviewed-by: Moritz Fischer <moritz.fischer@ettus.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Alan Tull authored and Greg Kroah-Hartman committed Nov 24, 2015
1 parent 1ec2183 commit 07687c0
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions drivers/fpga/fpga-mgr.c
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,6 @@ int fpga_mgr_register(struct device *dev, const char *name,
void *priv)
{
struct fpga_manager *mgr;
const char *dt_label;
int id, ret;

if (!mops || !mops->write_init || !mops->write ||
Expand Down Expand Up @@ -300,11 +299,9 @@ int fpga_mgr_register(struct device *dev, const char *name,
mgr->dev.id = id;
dev_set_drvdata(dev, mgr);

dt_label = of_get_property(mgr->dev.of_node, "label", NULL);
if (dt_label)
ret = dev_set_name(&mgr->dev, "%s", dt_label);
else
ret = dev_set_name(&mgr->dev, "fpga%d", id);
ret = dev_set_name(&mgr->dev, "fpga%d", id);
if (ret)
goto error_device;

ret = device_add(&mgr->dev);
if (ret)
Expand Down

0 comments on commit 07687c0

Please sign in to comment.