Skip to content

Commit

Permalink
core.packet: expose constants for packet alignment and headroom
Browse files Browse the repository at this point in the history
  • Loading branch information
eugeneia committed Nov 14, 2019
1 parent f535525 commit 6174563
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/core/packet.lua
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,11 @@ max_payload = tonumber(C.PACKET_PAYLOAD_SIZE)
-- For operations that add or remove headers from the beginning of a
-- packet, instead of copying around the payload we just move the
-- packet structure as a whole around.
local packet_alignment = 512
local default_headroom = 256
packet_alignment = 512
default_headroom = 256
-- The Intel82599 driver requires even-byte alignment, so let's keep
-- things aligned at least this much.
local minimum_alignment = 2
minimum_alignment = 2

local function get_alignment (addr, alignment)
-- Precondition: alignment is a power of 2.
Expand Down

0 comments on commit 6174563

Please sign in to comment.