Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a73ee843 authored by Rob Herring's avatar Rob Herring Committed by Greg Kroah-Hartman
Browse files

tty: Convert to using %pOF instead of full_name



Now that we have a custom printf format specifier, convert users of
full_name to use %pOF instead. This is preparation to remove storing
of the full path string for each node.

Signed-off-by: default avatarRob Herring <robh@kernel.org>
Acked-by: default avatarDavid S. Miller <davem@davemloft.net>
Cc: Jiri Slaby <jslaby@suse.com>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Michael Ellerman <mpe@ellerman.id.au>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: linuxppc-dev@lists.ozlabs.org
Cc: linux-serial@vger.kernel.org
Cc: sparclinux@vger.kernel.org
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 46d01710
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -122,7 +122,7 @@ static int find_console_handle(void)

	stdout_irq = irq_of_parse_and_map(np, 0);
	if (stdout_irq == NO_IRQ) {
		pr_err("ehv-bc: no 'interrupts' property in %s node\n", np->full_name);
		pr_err("ehv-bc: no 'interrupts' property in %pOF node\n", np);
		return 0;
	}

+8 −8
Original line number Diff line number Diff line
@@ -179,8 +179,8 @@ static int hvc_opal_probe(struct platform_device *dev)
		proto = HV_PROTOCOL_HVSI;
		ops = &hvc_opal_hvsi_ops;
	} else {
		pr_err("hvc_opal: Unknown protocol for %s\n",
		       dev->dev.of_node->full_name);
		pr_err("hvc_opal: Unknown protocol for %pOF\n",
		       dev->dev.of_node);
		return -ENXIO;
	}

@@ -204,14 +204,14 @@ static int hvc_opal_probe(struct platform_device *dev)
		/* Instanciate now to establish a mapping index==vtermno */
		hvc_instantiate(termno, termno, ops);
	} else {
		pr_err("hvc_opal: Device %s has duplicate terminal number #%d\n",
		       dev->dev.of_node->full_name, termno);
		pr_err("hvc_opal: Device %pOF has duplicate terminal number #%d\n",
		       dev->dev.of_node, termno);
		return -ENXIO;
	}

	pr_info("hvc%d: %s protocol on %s%s\n", termno,
	pr_info("hvc%d: %s protocol on %pOF%s\n", termno,
		proto == HV_PROTOCOL_RAW ? "raw" : "hvsi",
		dev->dev.of_node->full_name,
		dev->dev.of_node,
		boot ? " (boot console)" : "");

	irq = irq_of_parse_and_map(dev->dev.of_node, 0);
@@ -222,8 +222,8 @@ static int hvc_opal_probe(struct platform_device *dev)
	}

	if (!irq) {
		pr_err("hvc_opal: Unable to map interrupt for device %s\n",
			dev->dev.of_node->full_name);
		pr_err("hvc_opal: Unable to map interrupt for device %pOF\n",
			dev->dev.of_node);
		return irq;
	}

+3 −3
Original line number Diff line number Diff line
@@ -312,12 +312,12 @@ static int hvc_vio_probe(struct vio_dev *vdev,
		proto = HV_PROTOCOL_HVSI;
		ops = &hvterm_hvsi_ops;
	} else {
		pr_err("hvc_vio: Unknown protocol for %s\n", vdev->dev.of_node->full_name);
		pr_err("hvc_vio: Unknown protocol for %pOF\n", vdev->dev.of_node);
		return -ENXIO;
	}

	pr_devel("hvc_vio_probe() device %s, using %s protocol\n",
		 vdev->dev.of_node->full_name,
	pr_devel("hvc_vio_probe() device %pOF, using %s protocol\n",
		 vdev->dev.of_node,
		 proto == HV_PROTOCOL_RAW ? "raw" : "hvsi");

	/* Is it our boot one ? */
+1 −1
Original line number Diff line number Diff line
@@ -363,7 +363,7 @@ static int of_serdev_register_devices(struct serdev_controller *ctrl)
		if (!of_get_property(node, "compatible", NULL))
			continue;

		dev_dbg(&ctrl->dev, "adding child %s\n", node->full_name);
		dev_dbg(&ctrl->dev, "adding child %pOF\n", node);

		serdev = serdev_device_alloc(ctrl);
		if (!serdev)
+6 −6
Original line number Diff line number Diff line
@@ -1634,8 +1634,8 @@ mpc52xx_console_setup(struct console *co, char *options)
		return -EINVAL;
	}

	pr_debug("Console on ttyPSC%x is %s\n",
		 co->index, mpc52xx_uart_nodes[co->index]->full_name);
	pr_debug("Console on ttyPSC%x is %pOF\n",
		 co->index, mpc52xx_uart_nodes[co->index]);

	/* Fetch register locations */
	ret = of_address_to_resource(np, 0, &res);
@@ -1755,8 +1755,8 @@ static int mpc52xx_uart_of_probe(struct platform_device *op)
			break;
	if (idx >= MPC52xx_PSC_MAXNUM)
		return -EINVAL;
	pr_debug("Found %s assigned to ttyPSC%x\n",
		 mpc52xx_uart_nodes[idx]->full_name, idx);
	pr_debug("Found %pOF assigned to ttyPSC%x\n",
		 mpc52xx_uart_nodes[idx], idx);

	/* set the uart clock to the input clock of the psc, the different
	 * prescalers are taken into account in the set_baudrate() methods
@@ -1881,8 +1881,8 @@ mpc52xx_uart_of_enumerate(void)

	for (i = 0; i < MPC52xx_PSC_MAXNUM; i++) {
		if (mpc52xx_uart_nodes[i])
			pr_debug("%s assigned to ttyPSC%x\n",
				 mpc52xx_uart_nodes[i]->full_name, i);
			pr_debug("%pOF assigned to ttyPSC%x\n",
				 mpc52xx_uart_nodes[i], i);
	}
}

Loading