All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mohamad Raizudeen <raizudeen.kerneldev@gmail.com>
To: Herbert Xu <herbert@gondor.apana.org.au>
Cc: ebiggers@kernel.org, ardb@kernel.org, Jason@zx2c4.com,
	skhan@linuxfoundation.org, me@brighamcampbell.com,
	jkoolstra@xs4all.nl, linux-crypto@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] lib/crypto: md5: correct header inclusions
Date: Thu, 15 Oct 2026 10:48:35 +0530	[thread overview]
Message-ID: <atBiK2z2MKCeg-YA@kernel> (raw)
In-Reply-To: <atBa776tU-O1Qg-T@gondor.apana.org.au>

On Thu, Oct 15, 2026 at 03:47:43PM +1100, Herbert Xu wrote:
> Mohamad Raizudeen <raizudeen.kerneldev@gmail.com> wrote:
> > The file uses 'rol32()' inline function (inside the MD5STEP macro) but
> > does not explicitly include `<linux/bitops.h>`, currently relying on
> > indirect includes.
> > 
> > Also, `<linux/unaligned.h>` is included but never used, as the code
> > relies on direct pointer casts.
> > 
> > Add the missing `<linux/bitops.h>` and remove the unused
> > `<linux/unaligned.h>`.
> > 
> > Signed-off-by: Mohamad Raizudeen <raizudeen.kerneldev@gmail.com>
> > ---
> > lib/crypto/md5.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > diff --git a/lib/crypto/md5.c b/lib/crypto/md5.c
> > index 3d2b017a0525..a838bb90103f 100644
> > --- a/lib/crypto/md5.c
> > +++ b/lib/crypto/md5.c
> > @@ -13,10 +13,10 @@
> > #include <crypto/hmac.h>
> > #include <crypto/md5.h>
> > #include <linux/export.h>
> > +#include <linux/bitops.h>
> > #include <linux/kernel.h>
> 
> bitops.h is redundant because kernel.h already includes it.
> 
> Cheers,
> -- 
> Email: Herbert Xu <herbert@gondor.apana.org.au>
> Home Page: http://gondor.apana.org.au/~herbert/
> PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

Understood. I will drop the bitops.h addition. I will send a v2
that only removes the unused `<linux/unaligned.h>` include.

Thanks,
Mohamad Raizudeen

      reply	other threads:[~2026-10-15  5:18 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-15  3:38 [PATCH] lib/crypto: md5: correct header inclusions Mohamad Raizudeen
2026-10-15  4:47 ` Herbert Xu
2026-10-15  5:18   ` Mohamad Raizudeen [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=atBiK2z2MKCeg-YA@kernel \
    --to=raizudeen.kerneldev@gmail.com \
    --cc=Jason@zx2c4.com \
    --cc=ardb@kernel.org \
    --cc=ebiggers@kernel.org \
    --cc=herbert@gondor.apana.org.au \
    --cc=jkoolstra@xs4all.nl \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=me@brighamcampbell.com \
    --cc=skhan@linuxfoundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.