Skip to content

Commit

Permalink
doc: fix some syntax errors in netlink mmap sample code
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
Cong Wang authored and David S. Miller committed Jun 25, 2013
1 parent 3e4f8b7 commit 7623757
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Documentation/networking/netlink_mmap.txt
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit 7623757

Please sign in to comment.