/* * of.c The helpers for hcd device tree support * * Copyright (C) 2016 Freescale Semiconductor, Inc. * Author: Peter Chen * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 of * the License as published by the Free Software Foundation. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ #include #include /** * usb_of_get_child_node - Find the device node match port number * @parent: the parent device node * @portnum: the port number which device is connecting * * Find the node from device tree according to its port number. * * Return: On success, a pointer to the device node, %NULL on failure. */ struct device_node *usb_of_get_child_node(struct device_node *parent, int portnum) { struct device_node *node; u32 port; for_each_child_of_node(parent, node) { if (!of_property_read_u32(node, "reg", &port)) { if (port == portnum) return node; } } return NULL; } EXPORT_SYMBOL_GPL(usb_of_get_child_node); e>
summaryrefslogtreecommitdiff
si/fc?id=67d35e70af9cabb663c827e03bc5c1e89b43db72'>fc/fc_ns.h
diff options
AgeCommit message (Expand)AuthorFilesLines
context:
space:
mode:
authorFam Zheng <famz@redhat.com>2017-01-13 11:40:01 +0800
committerMartin K. Petersen <martin.petersen@oracle.com>2017-01-16 15:43:02 -0500
commit67d35e70af9cabb663c827e03bc5c1e89b43db72 (patch)
treeef130aab90e74e98ca4599f12011a7d80d3aa059 /include/uapi/scsi/fc/fc_ns.h
parentcd60be4916ae689387d04b86b6fc15931e4c95ae (diff)
scsi: libfc: Fix variable name in fc_set_wwpn
The parameter name should be wwpn instead of wwnn. Signed-off-by: Fam Zheng <famz@redhat.com> Acked-by: Johannes Thumshirn <jth@kernel.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'include/uapi/scsi/fc/fc_ns.h')