nx_build_sg_lists(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ NAME ✨

nx_build_sg_lists β€” okay so picture this: it walks the input scatterlists and builds arrays of NX scatterlists based on them πŸ’… like it literally strolls through your scatterlists and constructs the NX glow-up versions, no cap.

This is the Kernel API Manual page for it, bestie, and yes we're getting into it πŸŽ€


🌸 SYNOPSIS 🌸

int nx_build_sg_lists (struct nx_crypto_ctx *nx_ctx , const u8 *iv ,
struct scatterlist *dst , struct scatterlist *src , unsigned int *nbytes
, unsigned int offset , u8 *oiv );

Seven params, one int return, main character energy πŸ”₯


πŸ¦‹ ARGUMENTS πŸ¦‹

  • nx_ctx β€” the NX crypto context for the lists we're building πŸ’– it's giving "this is the context, the whole context, nothing but the context."
  • iv β€” iv data, if the algorithm requires it πŸ™ˆ so like, only sometimes, okay?
  • dst β€” destination scatterlist ✨ the place things are going.
  • src β€” source scatterlist πŸŽ€ the place things are coming from. iconic duo honestly.
  • nbytes β€” length of data described in the scatterlists πŸ“ the actual count, and it's a pointer, so pay attention.
  • offset β€” number of bytes to fast-forward past at the beginning of scatterlists ⏩ like skipping the intro of a song, but make it bytes.
  • oiv β€” destination for the iv data, if the algorithm requires it πŸ‘‘ the "o" is for output, the vibe is for slay.

πŸ’œ DESCRIPTION πŸ’œ

So here's the tea: this is common code shared by all the AES algorithms 🫢 like every single one, no favorites.

It uses the crypto scatterlist walk routines to traverse input and output scatterlists, building corresponding NX scatterlists 🌈 that's the whole bit β€” walk in, build out, repeat, periodt.

ngl bestie it really is that simple, this one's a helper through and through πŸ’€

🧚 SEE ALSO 🧚

Kernel file ./drivers/crypto/nx/nx.c β€” plus the whole friend group, go say hi:


okay that's the page, mwah πŸ’‹

Signed off from ./drivers/crypto/nx, dated October 2026, page nx_build_sg_lists(9) β€” go build those scatterlists bestie, you got this β­πŸ’–

πŸ“¦ where this page comes from