• Xu Yilun's avatar
    fpga: dfl: support multiple opens on feature device node. · b6862193
    Xu Yilun authored
    Each DFL functional block, e.g. AFU (Accelerated Function Unit) and FME
    (FPGA Management Engine), could implement more than one function within
    its region, but current driver only allows one user application to access
    it by exclusive open on device node. So this is not convenient and
    flexible for userspace applications, as they have to combine lots of
    different functions into one single application.
    
    This patch removes the limitation here to allow multiple opens to each
    feature device node for AFU and FME from userspace applications. If user
    still needs exclusive access to these device node, O_EXCL flag must be
    issued together with open.
    Signed-off-by: default avatarWu Hao <hao.wu@intel.com>
    Signed-off-by: default avatarXu Yilun <yilun.xu@intel.com>
    Signed-off-by: default avatarMoritz Fischer <mdf@kernel.org>
    b6862193
dfl.c 31.1 KB