summaryrefslogtreecommitdiff
path: root/Documentation
diff options
context:
space:
mode:
authorCong Wang <amwang@redhat.com>2013-06-24 19:46:54 +0800
committerDavid S. Miller <davem@davemloft.net>2013-06-25 16:47:02 -0700
commit762375766143aba42e74713f8364b4953c40a354 (patch)
tree128a6e26c63993440298af60b6c6b61b702b1e53 /Documentation
parent3e4f8b787370978733ca6cae452720a4f0c296b8 (diff)
doc: fix some syntax errors in netlink mmap sample code
Cc: Patrick McHardy <kaber@trash.net> Cc: David S. Miller <davem@davemloft.net> Signed-off-by: Cong Wang <amwang@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/networking/netlink_mmap.txt4
1 files changed, 2 insertions, 2 deletions
diff --git a/Documentation/networking/netlink_mmap.txt b/Documentation/networking/netlink_mmap.txt
index e6088baf109d..5cc600587778 100644
--- a/Documentation/networking/netlink_mmap.txt
+++ b/Documentation/networking/netlink_mmap.txt
@@ -274,9 +274,9 @@ This example assumes some ring parameters of the ring setup are available.
/* Get next frame header */
hdr = rx_ring + frame_offset;
- if (hdr->nm_status == NL_MMAP_STATUS_VALID)
+ if (hdr->nm_status == NL_MMAP_STATUS_VALID) {
/* Regular memory mapped frame */
- nlh = (void *hdr) + NL_MMAP_HDRLEN;
+ nlh = (void *)hdr + NL_MMAP_HDRLEN;
len = hdr->nm_len;
/* Release empty message immediately. May happen