mwifiex/mxm_wifiex/wlan_src/script/wifidirect/update_mac.sh
Fugang Duan 33d9f8e4f3 mxm_wifiex: add nxp mxm_wifiex sdk
Add initial MxM (multi-chip-multi-interface) wifi driver.
The driver target is to support 88w8987/88w8997/88w9098,
currently it only supports 88w8987.

The MxM wifi driver is merged from below repo and applied some
patches for block and build issues.
ssh://git@bitbucket.sw.nxp.com/wcswrel/
rel-nxp-wifi-fp92-bt-fp85-linux-android-mxm4x17169-gpl.git

The sdk only includes application, the driver already is
merged into linux kernel.

Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
2020-04-20 00:54:27 +08:00

17 lines
477 B
Bash

#!/bin/bash
MAC=`ifconfig wfd0 | grep wfd0 | tr -s ' ' | cut -d ' ' -f5`
MAC26=`echo $MAC | cut -d ':' -f2-6`
LAA=`echo $MAC | cut -d ':' -f1`
LAA=$((0x$LAA+2))
if [ $LAA -lt 16 ] ; then
LAA=`printf "%X\n" $LAA`
MACLAA=0$LAA:$MAC26
else
LAA=`printf "%X\n" $LAA`
MACLAA=$LAA:$MAC26
fi
sed "s/00:50:43:00:00:00/$MAC/" config/wifidirect.conf > tmp$$
mv tmp$$ config/wifidirect.conf
sed "s/02:50:43:00:00:00/$MACLAA/" config/wifidirect.conf > tmp$$
mv tmp$$ config/wifidirect.conf