]> git.baikalelectronics.ru Git - kernel.git/commit
arm64: make _TIF_WORK_MASK bits contiguous
authorMark Rutland <mark.rutland@arm.com>
Wed, 16 Dec 2020 21:32:48 +0000 (21:32 +0000)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 16 Dec 2020 22:08:47 +0000 (14:08 -0800)
commit805ddde71f3f0aae0125baea2e9ba0d5b055cdb5
treec047c19cbfeed18571b3d63c20466903e10e3bda
parent63494684068bb8ce8875640f7fc7994d9efdcfb4
arm64: make _TIF_WORK_MASK bits contiguous

We need the bits of _TIF_WORK_MASK to be contiguous in order to to use
this as an immediate argument to an AND instruction in entry.S.

We happened to change these bits in commits:

  fcc7bbfdaddb ("arm64: uaccess: remove addr_limit_user_check()")
  3f4c4fcbccbd ("arm64: add support for TIF_NOTIFY_SIGNAL")

which each worked in isolation, but the merge resolution in commit:

  35182b5a2333 ("Merge tag 'tif-task_work.arch-2020-12-14' of git://git.kernel.dk/linux-block")

happened to make the bits non-contiguous.

Fix this by moving TIF_NOTIFY_SIGNAL to be bit 6, which is contiguous
with the rest of _TIF_WORK_MASK.

Otherwise, we'll get a build-time failure as below:

   arch/arm64/kernel/entry.S: Assembler messages:
   arch/arm64/kernel/entry.S:733: Error: immediate out of range at operand 3 -- `and x2,x19,#((1<<1)|(1<<0)|(1<<2)|(1<<3)|(1<<4)|(1<<5)|(1<<7))'
   scripts/Makefile.build:360: recipe for target 'arch/arm64/kernel/entry.o' failed

Fixes: 35182b5a23335d1d ("Merge tag 'tif-task_work.arch-2020-12-14' of git://git.kernel.dk/linux-block")
Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Will Deacon <will@kernel.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
arch/arm64/include/asm/thread_info.h