Hi Jeffrey-
   I opened a case with IBM and they acknowledged the problem and are going to 
look into how to resolve.  You are correct it is present in AIX 7.2 as well, 
though I thought I had it building on 7.2.  Obviously not.  I will submit my 
patches for 7.3 here shortly and then go double-check 7.2.

   In the mean time, this is the gist of what I'm proposing as a work-around, 
instead of adding or generating an empty header:

diff --git a/src/rx/AIX/rx_knet.c b/src/rx/AIX/rx_knet.c
index 54a6c8583..19d9ecaac 100644
--- a/src/rx/AIX/rx_knet.c
+++ b/src/rx/AIX/rx_knet.c
@@ -72,7 +72,12 @@ rxk_input(struct mbuf *am, int hlen)
  * are in a separate kernel extension, and they are unwilling to export their
  * symbols to us.  We can get there indirectly, however.
  */
+#ifdef AFS_AIX72_ENV /* Avoid including net/netisr.h on AIX 7.2 and higher */
+#define NETISR_MAX     64
+#define NET_KPROC      0
+#else
 #include <net/netisr.h>
+#endif
 static struct ifqueue rxk_q;   /* RXKluge queue        */
 static struct arpcom rxk_bogosity;

Thank you!

-Ben



________________________________
From: Jeffrey E Altman
Sent: Tuesday, January 31, 2023 10:14 AM
To: Ben Huntsman; openafs-devel@openafs.org
Subject: Re: [OpenAFS-devel] Where to put new header file

On 1/31/2023 12:17 PM, Ben Huntsman 
(b...@huntsmans.net<mailto:b...@huntsmans.net>) wrote:
#ifdef  _KERNEL

#ifdef  _AIX_FULLOSF
#include "kern/queue.h"
#include "kern/thread.h"
#include "kern/sched_prim.h"
#else
#define EVENT_NETISR    0x0726
#include <sys/libsysp.h>        /* remque/insque */
#endif
...


The above block of code appears to be present in net/netisr.h on AIX 7.2 as 
well.


I might have missed something but it appears the only defines OpenAFS uses from 
net/netisr.h are:


/* AIX 3.x compatibility defines */
#define NETISR_MAX      64
#define NET_KPROC       0


These are used in the add_input_type() call.

NET_KPROC has always been 0 and I think OpenAFS should be using NETISR_AFS (33) 
instead of (NETISR_MAX - 1).


If an empty file needs to be created, please do not add it to the repository.  
Instead, I suggest creating it at build time.


Jeffrey Altman



Reply via email to