05 Aug, 2010
2 commits
-
* 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (48 commits)
Documentation: update broken web addresses.
fix comment typo "choosed" -> "chosen"
hostap:hostap_hw.c Fix typo in comment
Fix spelling contorller -> controller in comments
Kconfig.debug: FAIL_IO_TIMEOUT: typo Faul -> Fault
fs/Kconfig: Fix typo Userpace -> Userspace
Removing dead MACH_U300_BS26
drivers/infiniband: Remove unnecessary casts of private_data
fs/ocfs2: Remove unnecessary casts of private_data
libfc: use ARRAY_SIZE
scsi: bfa: use ARRAY_SIZE
drm: i915: use ARRAY_SIZE
drm: drm_edid: use ARRAY_SIZE
synclink: use ARRAY_SIZE
block: cciss: use ARRAY_SIZE
comment typo fixes: charater => character
fix comment typos concerning "challenge"
arm: plat-spear: fix typo in kerneldoc
reiserfs: typo comment fix
update email address
... -
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6: (1443 commits)
phy/marvell: add 88ec048 support
igb: Program MDICNFG register prior to PHY init
e1000e: correct MAC-PHY interconnect register offset for 82579
hso: Add new product ID
can: Add driver for esd CAN-USB/2 device
l2tp: fix export of header file for userspace
can-raw: Fix skb_orphan_try handling
Revert "net: remove zap_completion_queue"
net: cleanup inclusion
phy/marvell: add 88e1121 interface mode support
u32: negative offset fix
net: Fix a typo from "dev" to "ndev"
igb: Use irq_synchronize per vector when using MSI-X
ixgbevf: fix null pointer dereference due to filter being set for VLAN 0
e1000e: Fix irq_synchronize in MSI-X case
e1000e: register pm_qos request on hardware activation
ip_fragment: fix subtracting PPPOE_SES_HLEN from mtu twice
net: Add getsockopt support for TCP thin-streams
cxgb4: update driver version
cxgb4: add new PCI IDs
...Manually fix up conflicts in:
- drivers/net/e1000e/netdev.c: due to pm_qos registration
infrastructure changes
- drivers/net/phy/marvell.c: conflict between adding 88ec048 support
and cleaning up the IDs
- drivers/net/wireless/ipw2x00/ipw2100.c: trivial ipw2100_pm_qos_req
conflict (registration change vs marking it static)
04 Aug, 2010
1 commit
03 Aug, 2010
21 commits
-
Commit fc6055a5ba31e2c14e36e8939f9bf2b6d586a7f5 (net: Introduce
skb_orphan_try()) allows an early orphan of the skb and takes care on
tx timestamping, which needs the sk-reference in the skb on driver level.
So does the can-raw socket, which has not been taken into account here.The patch below adds a 'prevent_sk_orphan' bit in the skb tx shared info,
which fixes the problem discovered by Matthias Fuchs here:http://marc.info/?t=128030411900003&r=1&w=2
Even if it's not a primary tx timestamp topic it fits well into some skb
shared tx context. Or should be find a different place for the information to
protect the sk reference until it reaches the driver level?Signed-off-by: Oliver Hartkopp
Signed-off-by: David S. Miller -
This reverts commit 15e83ed78864d0625e87a85f09b297c0919a4797.
As explained by Johannes Berg, the optimization made here is
invalid. Or, at best, incomplete.Not only destructor invocation, but conntract entry releasing
must be executed outside of hw IRQ context.So just checking "skb->destructor" is insufficient.
Signed-off-by: David S. Miller
-
Commit ab95bfe01f9872459c8678572ccadbf646badad0 replaces bridge and macvlan
hooks in __netif_receive_skb(), so dev.c doesn't need to include their headers.Signed-off-by: Changli Gao
Signed-off-by: David S. Miller -
Conflicts:
drivers/net/e1000e/hw.h
net/bridge/br_device.c
net/bridge/br_input.c -
It was possible to use a negative offset in a u32 match to reference
the ethernet header or other parts of the link layer header.
This fixes the regression caused by:commit fbc2e7d9cf49e0bf89b9e91fd60a06851a855c5d
Author: Changli Gao
Date: Wed Jun 2 07:32:42 2010 -0700cls_u32: use skb_header_pointer() to dereference data safely
Signed-off-by: Stephen Hemminger
Signed-off-by: David S. Miller -
6c79bf0f2440fd250c8fce8d9b82fcf03d4e8350 subtracts PPPOE_SES_HLEN from mtu at
the front of ip_fragment(). So the later subtraction should be removed. The
MTU of 802.1q is also 1500, so MTU should not be changed.Signed-off-by: Changli Gao
Signed-off-by: Bart De Schuymer
----
net/ipv4/ip_output.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
Signed-off-by: Bart De Schuymer
Signed-off-by: David S. Miller -
Initial TCP thin-stream commit did not add getsockopt support for the new
socket options: TCP_THIN_LINEAR_TIMEOUTS and TCP_THIN_DUPACK. This adds support
for them.Signed-off-by: Josh Hunt
Tested-by: Andreas Petlund
Acked-by: Andreas Petlund
Signed-off-by: David S. Miller -
9P spec says:
"It is correct to consider remove to be a clunk with the
side effect of removing the file if permissions allow. "So even if remove fails we need to destroy the fid.
Without this patch an rmdir on a directory with contents leave
the new cloned directory fid fid attached to fidlist. On umount
we dump the fids on the fidlist~# rmdir /mnt2/test4/
rmdir: failed to remove `/mnt2/test4/': Directory not empty
~# umount /mnt2/
~# dmesg
[ 228.474323] Found fid 3 not clunkedSigned-off-by: Aneesh Kumar K.V
Signed-off-by: Venkateswararao Jujjuri
Signed-off-by: Eric Van Hensbergen -
TXATTRCREATE: Prepare a fid for setting xattr value on a file system object.
size[4] TXATTRCREATE tag[2] fid[4] name[s] attr_size[8] flags[4]
size[4] RXATTRCREATE tag[2]txattrcreate gets a fid pointing to xattr. This fid can later be
used to set the xattr value.flag value is derived from set Linux setxattr. The manpage says
"The flags parameter can be used to refine the semantics of the operation.
XATTR_CREATE specifies a pure create, which fails if the named attribute
exists already. XATTR_REPLACE specifies a pure replace operation, which
fails if the named attribute does not already exist. By default (no flags),
the extended attribute will be created if need be, or will simply replace
the value if the attribute exists."The actual setxattr operation happens when the fid is clunked. At that point
the written byte count and the attr_size specified in TXATTRCREATE should be
same otherwise an error will be returned.Signed-off-by: Aneesh Kumar K.V
Signed-off-by: Venkateswararao Jujjuri
Signed-off-by: Eric Van Hensbergen -
TXATTRWALK: Descend a ATTR namespace
size[4] TXATTRWALK tag[2] fid[4] newfid[4] name[s]
size[4] RXATTRWALK tag[2] size[8]txattrwalk gets a fid pointing to xattr. This fid can later be
used to read the xattr value. If name is NULL the fid returned
can be used to get the list of extended attribute associated to
the file system object.Signed-off-by: Aneesh Kumar K.V
Signed-off-by: Venkateswararao Jujjuri
Signed-off-by: Eric Van Hensbergen -
Implement 9p2000.L version of open(LOPEN) interface in 9p client.
For LOPEN, no need to convert the flags to and from 9p mode to VFS mode.
Synopsis:
size[4] Tlopen tag[2] fid[4] mode[4]
size[4] Rlopen tag[2] qid[13] iounit[4]
[Fix mode bit format - jvrao@linux.vnet.ibm.com]
Signed-off-by: M. Mohan Kumar
Signed-off-by: Venkateswararao Jujjuri
Signed-off-by: Eric Van Hensbegren -
SYNOPSIS
size[4] Tlcreate tag[2] fid[4] name[s] flags[4] mode[4] gid[4]
size[4] Rlcreate tag[2] qid[13] iounit[4]
DESCRIPTION
The Tlreate request asks the file server to create a new regular file with the
name supplied, in the directory (dir) represented by fid.
The mode argument specifies the permissions to use. New file is created with
the uid if the fid and with supplied gid.The flags argument represent Linux access mode flags with which the caller
is requesting to open the file with. Protocol allows all the Linux access
modes but it is upto the server to allow/disallow any of these acess modes.
If the server doesn't support any of the access mode, it is expected to
return error.Signed-off-by: Venkateswararao Jujjuri
Signed-off-by: Eric Van Hensbergen -
Implement TMKDIR as part of 2000.L Work
Synopsis
size[4] Tmkdir tag[2] fid[4] name[s] mode[4] gid[4]
size[4] Rmkdir tag[2] qid[13]
Description
mkdir asks the file server to create a directory with given name,
mode and gid. The qid for the new directory is returned with
the mkdir reply message.Note: 72 is selected as the opcode for TMKDIR from the reserved list.
Signed-off-by: M. Mohan Kumar
Signed-off-by: Venkateswararao Jujjuri
Signed-off-by: Eric Van Hensbergen -
Synopsis
size[4] Tmknod tag[2] fid[4] name[s] mode[4] major[4] minor[4] gid[4]
size[4] Rmknod tag[2] qid[13]
Description
mknod asks the file server to create a device node with given major and
minor number, mode and gid. The qid for the new device node is returned
with the mknod reply message.[sripathik@in.ibm.com: Fix error handling code]
Signed-off-by: M. Mohan Kumar
Signed-off-by: Venkateswararao Jujjuri
Signed-off-by: Eric Van Hensbergen -
Create a symbolic link
SYNOPSIS
size[4] Tsymlink tag[2] fid[4] name[s] symtgt[s] gid[4]
size[4] Rsymlink tag[2] qid[13]
DESCRIPTION
Create a symbolic link named 'name' pointing to 'symtgt'.
gid represents the effective group id of the caller.
The permissions of a symbolic link are irrelevant hence it is omitted
from the protocol.Signed-off-by: Venkateswararao Jujjuri
Reviewed-by: Sripathi Kodi
Signed-off-by: Eric Van Hensbergen -
This patch adds a helper function to get the dentry from inode and
uses it in creating a HardlinkSYNOPSIS
size[4] Tlink tag[2] dfid[4] oldfid[4] newpath[s]
size[4] Rlink tag[2]
DESCRIPTION
Create a link 'newpath' in directory pointed by dfid linking to oldfid path.
[sripathik@in.ibm.com : p9_client_link should not free req structure
if p9_client_rpc has returned an error.]Signed-off-by: Venkateswararao Jujjuri
Signed-off-by: Eric Van Hensbergen -
SYNOPSIS
size[4] Tsetattr tag[2] attr[n]
size[4] Rsetattr tag[2]
DESCRIPTION
The setattr command changes some of the file status information.
attr resembles the iattr structure used in Linux kernel. It
specifies which status parameter is to be changed and to what
value. It is laid out as follows:valid[4]
specifies which status information is to be changed. Possible
values are:
ATTR_MODE (1 << 0)
ATTR_UID (1 << 1)
ATTR_GID (1 << 2)
ATTR_SIZE (1 << 3)
ATTR_ATIME (1 << 4)
ATTR_MTIME (1 << 5)
ATTR_ATIME_SET (1 << 7)
ATTR_MTIME_SET (1 << 8)The last two bits represent whether the time information
is being sent by the client's user space. In the absense
of these bits the server always uses server's time.mode[4]
File permission bitsuid[4]
Owner id of filegid[4]
Group id of the filesize[8]
File sizeatime_sec[8]
Time of last file access, secondsatime_nsec[8]
Time of last file access, nanosecondsmtime_sec[8]
Time of last file modification, secondsmtime_nsec[8]
Time of last file modification, nanosecondsExplanation of the patches:
--------------------------*) The kernel just copies relevent contents of iattr structure to
p9_iattr_dotl structure and passes it down to the client. The
only check it has is calling inode_change_ok()
*) The p9_iattr_dotl structure does not have ctime and ia_file
parameters because I don't think these are needed in our case.
The client user space can request updating just ctime by calling
chown(fd, -1, -1). This is handled on server side without a need
for putting ctime on the wire.
*) The server currently supports changing mode, time, ownership and
size of the file.
*) 9P RFC says "Either all the changes in wstat request happen, or
none of them does: if the request succeeds, all changes were made;
if it fails, none were."
I have not done anything to implement this specifically because I
don't see a reason.Signed-off-by: Sripathi Kodi
Signed-off-by: Venkateswararao Jujjuri
Signed-off-by: Eric Van Hensbergen -
SYNOPSIS
size[4] Tgetattr tag[2] fid[4] request_mask[8]
size[4] Rgetattr tag[2] lstat[n]
DESCRIPTION
The getattr transaction inquires about the file identified by fid.
request_mask is a bit mask that specifies which fields of the
stat structure is the client interested in.The reply will contain a machine-independent directory entry,
laid out as follows:st_result_mask[8]
Bit mask that indicates which fields in the stat structure
have been populated by the serverqid.type[1]
the type of the file (directory, etc.), represented as a bit
vector corresponding to the high 8 bits of the file's mode
word.qid.vers[4]
version number for given pathqid.path[8]
the file server's unique identification for the filest_mode[4]
Permission and flagsst_uid[4]
User id of ownerst_gid[4]
Group ID of ownerst_nlink[8]
Number of hard linksst_rdev[8]
Device ID (if special file)st_size[8]
Size, in bytesst_blksize[8]
Block size for file system IOst_blocks[8]
Number of file system blocks allocatedst_atime_sec[8]
Time of last access, secondsst_atime_nsec[8]
Time of last access, nanosecondsst_mtime_sec[8]
Time of last modification, secondsst_mtime_nsec[8]
Time of last modification, nanosecondsst_ctime_sec[8]
Time of last status change, secondsst_ctime_nsec[8]
Time of last status change, nanosecondsst_btime_sec[8]
Time of creation (birth) of file, secondsst_btime_nsec[8]
Time of creation (birth) of file, nanosecondsst_gen[8]
Inode generationst_data_version[8]
Data version numberrequest_mask and result_mask bit masks contain the following bits
#define P9_STATS_MODE 0x00000001ULL
#define P9_STATS_NLINK 0x00000002ULL
#define P9_STATS_UID 0x00000004ULL
#define P9_STATS_GID 0x00000008ULL
#define P9_STATS_RDEV 0x00000010ULL
#define P9_STATS_ATIME 0x00000020ULL
#define P9_STATS_MTIME 0x00000040ULL
#define P9_STATS_CTIME 0x00000080ULL
#define P9_STATS_INO 0x00000100ULL
#define P9_STATS_SIZE 0x00000200ULL
#define P9_STATS_BLOCKS 0x00000400ULL#define P9_STATS_BTIME 0x00000800ULL
#define P9_STATS_GEN 0x00001000ULL
#define P9_STATS_DATA_VERSION 0x00002000ULL#define P9_STATS_BASIC 0x000007ffULL
#define P9_STATS_ALL 0x00003fffULLThis patch implements the client side of getattr implementation for
9P2000.L. It introduces a new structure p9_stat_dotl for getting
Linux stat information along with QID. The data layout is similar to
stat structure in Linux user space with the following major
differences:inode (st_ino) is not part of data. Instead qid is.
device (st_dev) is not part of data because this doesn't make sense
on the client.All time variables are 64 bit wide on the wire. The kernel seems to use
32 bit variables for these variables. However, some of the architectures
have used 64 bit variables and glibc exposes 64 bit variables to user
space on some architectures. Hence to be on the safer side we have made
these 64 bit in the protocol. Refer to the comments in
include/asm-generic/stat.hThere are some additional fields: st_btime_sec, st_btime_nsec, st_gen,
st_data_version apart from the bitmask, st_result_mask. The bit mask
is filled by the server to indicate which stat fields have been
populated by the server. Currently there is no clean way for the
server to obtain these additional fields, so it sends back just the
basic fields.Signed-off-by: Sripathi Kodi
Signed-off-by: Eric Van Hensbegren -
We need to get the negative errno value in the kernel
even for dotl.Signed-off-by: Aneesh Kumar K.V
Signed-off-by: Eric Van Hensbergen -
This patch implements the kernel part of readdir() implementation for 9p2000.L
Change from V3: Instead of inode, server now sends qids for each dirent
SYNOPSIS
size[4] Treaddir tag[2] fid[4] offset[8] count[4]
size[4] Rreaddir tag[2] count[4] data[count]DESCRIPTION
The readdir request asks the server to read the directory specified by 'fid'
at an offset specified by 'offset' and return as many dirent structures as
possible that fit into count bytes. Each dirent structure is laid out as
follows.qid.type[1]
the type of the file (directory, etc.), represented as a bit
vector corresponding to the high 8 bits of the file's mode
word.qid.vers[4]
version number for given pathqid.path[8]
the file server's unique identification for the fileoffset[8]
offset into the next dirent.type[1]
type of this directory entry.name[256]
name of this directory entry.This patch adds v9fs_dir_readdir_dotl() as the readdir() call for 9p2000.L.
This function sends P9_TREADDIR command to the server. In response the server
sends a buffer filled with dirent structures. This is different from the
existing v9fs_dir_readdir() call which receives stat structures from the server.
This results in significant speedup of readdir() on large directories.
For example, doing 'ls >/dev/null' on a directory with 10000 files on my
laptop takes 1.088 seconds with the existing code, but only takes 0.339 seconds
with the new readdir.Signed-off-by: Sripathi Kodi
Reviewed-by: Aneesh Kumar K.V
Signed-off-by: Eric Van Hensbergen
02 Aug, 2010
9 commits
-
use skb->len for accounting as xt_quota does. Since nf_conntrack works
at the network layer, skb_network_offset should always returns ZERO.Signed-off-by: Changli Gao
Signed-off-by: Patrick McHardy -
This is an off by one bug because strlen() doesn't count the NULL
terminator. We strcpy() addr into a fixed length array of size
UNIX_PATH_MAX later on.The addr variable is the name of the device being mounted.
Signed-off-by: Dan Carpenter
Signed-off-by: Eric Van Hensbergen -
The tuple got from unique_tuple() doesn't need to be really unique, so the
check for the unique tuple isn't necessary, when there isn't any other
choice. Eliminating the unnecessary nf_nat_used_tuple() can save some CPU
cycles too.Signed-off-by: Changli Gao
Signed-off-by: Patrick McHardy -
The only user of unique_tuple() get_unique_tuple() doesn't care about the
return value of unique_tuple(), so make unique_tuple() return void (nothing).Signed-off-by: Changli Gao
Signed-off-by: Patrick McHardy -
Use local variable hdrlen instead of ip_hdrlen(skb).
Signed-off-by: Changli Gao
Signed-off-by: Patrick McHardy -
This removes duplicate code by providing a default implementation
which is used by 3 of the 4 modules that provide these call.Signed-off-by: Simon Horman
Signed-off-by: Patrick McHardy -
IPVS was merged into the kernel quite a long time ago and
has been seeing wide-spread production use for even longer.It seems appropriate for it to be no longer tagged as EXPERIMENTAL
Signed-off-as: Simon Horman
Signed-off-by: Patrick McHardy -
some users of nf_ct_ext_exist() know ct->ext isn't NULL. For these users, the
check for ct->ext isn't necessary, the function __nf_ct_ext_exist() can be
used instead.the type of the return value of nf_ct_ext_exist() is changed to bool.
Signed-off-by: Changli Gao
Signed-off-by: Patrick McHardy -
We currently disable BH for the whole duration of get_counters()
On machines with a lot of cpus and large tables, this might be too long.
We can disable preemption during the whole function, and disable BH only
while fetching counters for the current cpu.Signed-off-by: Eric Dumazet
Signed-off-by: Patrick McHardy
01 Aug, 2010
4 commits
-
If user misconfigures ingress and causes a redirection loop, don't
overwhelm the log. This is also a error case so make it unlikely.
Found by inspection, luckily not in real system.Signed-off-by: Stephen Hemminger
Signed-off-by: David S. Miller -
The other calls to kmalloc in the same function use GFP_ATOMIC, and indeed
two locks are held within the body of the function.The semantic match that finds this problem is as follows:
(http://coccinelle.lip6.fr/)//
@@ identifier f; @@*f(...,GFP_ATOMIC,...)
... when != spin_unlock(...)
when != read_unlock(...)
when != write_unlock(...)
when != read_unlock_irq(...)
when != write_unlock_irq(...)
when != read_unlock_irqrestore(...)
when != write_unlock_irqrestore(...)
when != spin_unlock_irq(...)
when != spin_unlock_irqrestore(...)
*f(...,GFP_KERNEL,...)
//Signed-off-by: Julia Lawall
Signed-off-by: David S. Miller -
after updating the value of the ICMP payload, inet_proto_csum_replace4() should
be called with zero pseudohdr.Signed-off-by: Changli Gao
Acked-by: Herbert Xu
Signed-off-by: David S. Miller -
pskb_may_pull() may change skb pointers, so adjust icmph after pskb_may_pull().
Signed-off-by: Changli Gao
Acked-by: Herbert Xu
Signed-off-by: David S. Miller
31 Jul, 2010
3 commits
-
Currently you cannot disable multicast snooping while a device is
down. There is no good reason for this restriction and this patch
removes it.Signed-off-by: Herbert Xu
Signed-off-by: David S. Miller -
On the bridge TX path we're leaking an skb when br_multicast_rcv
returns an error.Reported-by: David Lamparter
Signed-off-by: Herbert Xu
Signed-off-by: David S. Miller -
There is a bug in do_tcp_setsockopt(net/ipv4/tcp.c),
TCP_COOKIE_TRANSACTIONS case.
In some cases (when tp->cookie_values == NULL) new tcp_cookie_values
structure can be allocated (at cvp), but not bound to
tp->cookie_values. So a memory leak occurs.Signed-off-by: Dmitry Popov
Signed-off-by: David S. Miller