'\" t .\" Title: dev_get_by_name .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.78.1 .\" Date: January 2017 .\" Manual: Network device support .\" Source: Kernel Hackers Manual 4.8.15 .\" Language: English .\" .TH "DEV_GET_BY_NAME" "9" "January 2017" "Kernel Hackers Manual 4\&.8\&." "Network device support" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" dev_get_by_name \- find a device by its name .SH "SYNOPSIS" .HP \w'struct\ net_device\ *\ dev_get_by_name('u .BI "struct net_device * dev_get_by_name(struct\ net\ *\ " "net" ", const\ char\ *\ " "name" ");" .SH "ARGUMENTS" .PP \fInet\fR .RS 4 the applicable net namespace .RE .PP \fIname\fR .RS 4 name to find .RE .SH "DESCRIPTION" .PP Find an interface by name\&. This can be called from any context and does its own locking\&. The returned handle has the usage count incremented and the caller must use \fBdev_put\fR to release it when it is no longer needed\&. \fBNULL\fR is returned if no matching device is found\&. .SH "COPYRIGHT" .br