summaryrefslogtreecommitdiffstats
path: root/Documentation/features/list-arch.sh
blob: 6065124a072f9b0229e77489462a001e884a01a1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#
# Small script that visualizes the kernel feature support status
# of an architecture.
#
# (If no arguments are given then it will print the host architecture's status.)
#

ARCH=${1:-$(arch | sed 's/x86_64/x86/' | sed 's/i386/x86/')}

cd $(dirname $0)
echo "#"
echo "# Kernel feature support matrix of the '$ARCH' architecture:"
echo "#"

for F in */*/arch-support.txt; do
  SUBSYS=$(echo $F | cut -d/ -f1)
  N=$(grep -h "^# Feature name:"        $F | cut -c25-)
  C=$(grep -h "^#         Kconfig:"     $F | cut -c25-)
  D=$(grep -h "^#         description:" $F | cut -c25-)
  S=$(grep -hw $ARCH $F | cut -d\| -f3)

  printf "%10s/%-22s:%s| %35s # %s\n" "$SUBSYS" "$N" "$S" "$C" "$D"
done

OpenPOWER on IntegriCloud