X-Git-Url: http://git.cascardo.info/?p=cascardo%2Flinux.git;a=blobdiff_plain;f=Documentation%2Fnetworking%2Fnetlink_mmap.txt;h=533378839546f9271022189c96ee9d440b44e9ae;hp=9bd0f5211e9a61b43f8e227a8681ab6683aa7806;hb=496322bc91e35007ed754184dcd447a02b6dd685;hpb=2e17c5a97e231f3cb426f4b7895eab5be5c5442e diff --git a/Documentation/networking/netlink_mmap.txt b/Documentation/networking/netlink_mmap.txt index 9bd0f5211e9a..533378839546 100644 --- a/Documentation/networking/netlink_mmap.txt +++ b/Documentation/networking/netlink_mmap.txt @@ -114,7 +114,7 @@ Some parameters are constrained, specifically: - nm_frame_nr must equal the actual number of frames as specified above. When the kernel can't allocate physically continuous memory for a ring block, -it will fall back to use physically discontinous memory. This might affect +it will fall back to use physically discontinuous memory. This might affect performance negatively, in order to avoid this the nm_frame_size parameter should be chosen to be as small as possible for the required frame size and the number of blocks should be increased instead. @@ -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