Skip to content

Commit

Permalink
xive: Mark XIVE owned EQs with a specific flag
Browse files Browse the repository at this point in the history
This will allow us to recognize them later when doing a
reset and avoid freeing them

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
  • Loading branch information
ozbenh authored and stewartsmith committed Jan 5, 2017
1 parent 2026df3 commit dc6b898
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 2 additions & 1 deletion hw/xive.c
Original file line number Diff line number Diff line change
Expand Up @@ -632,7 +632,8 @@ static void xive_init_eq(uint32_t vp_blk, uint32_t vp_idx,
eq->w7 = SETFIELD(EQ_W7_F0_PRIORITY, 0ul, prio);
eieio();
eq->w0 = EQ_W0_VALID | EQ_W0_ENQUEUE |
SETFIELD(EQ_W0_QSIZE, 0ul, EQ_QSIZE_64K);
SETFIELD(EQ_W0_QSIZE, 0ul, EQ_QSIZE_64K) |
EQ_W0_FIRMWARE;
#ifdef EQ_ALWAYS_NOTIFY
eq->w0 |= EQ_W0_UCOND_NOTIFY;
#endif
Expand Down
2 changes: 2 additions & 0 deletions include/xive.h
Original file line number Diff line number Diff line change
Expand Up @@ -355,6 +355,8 @@ struct xive_eq {
#define EQ_W0_ESCALATE_CTL PPC_BIT32(5)
#define EQ_W0_END_OF_INTR PPC_BIT32(6)
#define EQ_W0_QSIZE PPC_BITMASK32(12,15)
#define EQ_W0_SW0 PPC_BIT32(16)
#define EQ_W0_FIRMWARE EQ_W0_SW0 /* Owned by FW */
#define EQ_QSIZE_4K 0
#define EQ_QSIZE_64K 4
#define EQ_W0_HWDEP PPC_BITMASK32(24,31)
Expand Down

0 comments on commit dc6b898

Please sign in to comment.