.\" This manpage has been automatically generated by docbook2man
.\" from a DocBook document. This tool can be found at:
.\"
.\" Please send any bug reports, improvements, comments, patches,
.\" etc. to Steve Cheng .
.TH "__DEV_ALLOC" "" "06 October 2005" "" ""
.SH NAME
__dev_alloc \- allocate a network device and name
.SH SYNOPSIS
"SYNOPSIS"
.sp
\fB
.sp
struct net_device * __dev_alloc (const char * \fIname\fB, int * \fIerr\fB);
\fR
.SH "ARGUMENTS"
.TP
\fB\fIname\fB\fR
name format string
.TP
\fB\fIerr\fB\fR
error return pointer
.SH "DESCRIPTION"
.PP
Passed a format string, eg. ``ltd'', it will allocate a network device
and space for the name. NULL is returned if no memory is available.
If the allocation succeeds then the name is assigned and the
device pointer returned. NULL is returned if the name allocation
failed. The cause of an error is returned as a negative errno code
in the variable \fIerr\fR points to.
.PP
This call is deprecated in favor of alloc_netdev because
the caller must hold the \fIdev_base\fR or RTNL locks when doing this in
order to avoid duplicate name allocations.