Thanks for clarifying.

Yongho

2026년 9월 9일 (수) 오전 2:48, Lizhi Hou <[email protected]>님이 작성:
>
>
> On 9/2/26 22:48, 안용호 wrote:
> > Hi,
> >
> > I was looking at the hardware-context priority path in amdxdna and
> > noticed a difference between AIE2 and AIE4. I'm wondering whether this
> > is intentional.
> >
> > In aie2_message.c, aie2_get_context_priority() maps a qos.priority
> > value that matches none of the AMDXDNA_QOS_*_PRIORITY constants to
> > PRIORITY_HIGH:
> >
> > ```
> >      default:
> >              return PRIORITY_HIGH;
> > ```
> >
> > The function also returns PRIORITY_HIGH unconditionally when
> > AIE2_PREEMPT is not enabled.
> >
> > The XRT/xdna shim zero-initializes amdxdna_qos_info and only sets
> > qos.priority when a priority is explicitly specified. Thus, with no
> > explicit priority, qos.priority reaches the kernel as 0. Since the
> > defined priority values start at 0x100, 0 takes the default branch and
> > the resulting firmware context priority is HIGH.
> >
> > For comparison, aie4_parse_priority_to_dev() in the out-of-tree
> > xdna-driver maps an unrecognized priority value to
> > AIE4_CONTEXT_PRIORITY_BAND_NORMAL.
> >
> > Is the AIE2 default intentionally HIGH, or should the fallback be
>
> This is by design. The firmware running on AIE2 and AIE4 are different
> and they would use different default priority.
>
> Lizhi
>
> > PRIORITY_NORMAL, consistent with AIE4? I'd be happy to send a patch if
> > the latter is intended.
> >
> > This is against current linux.git master and amd/xdna-driver main as of
> > 2026-09-02.
> >
> > Thanks,
> > Yongho Ahn

Reply via email to