mirror of
https://gitlab.com/etherlab.org/ethercat.git
synced 2026-02-07 12:21:49 +08:00
22 lines
447 B
Bash
Executable File
22 lines
447 B
Bash
Executable File
#!/bin/bash
|
|
|
|
set -x
|
|
|
|
KERNELDIR=/data/kernel/linux-4.4.162
|
|
PREVER=3.16
|
|
KERNELVER=4.4
|
|
|
|
for f in $KERNELDIR/drivers/net/ethernet/{realtek/8139too,realtek/r8169,intel/e100}.c; do
|
|
echo $f
|
|
b=$(basename $f)
|
|
o=${b/\./-$KERNELVER-orig.}
|
|
e=${b/\./-$KERNELVER-ethercat.}
|
|
cp -v $f $o
|
|
chmod 644 $o
|
|
cp -v $o $e
|
|
op=${b/\./-$PREVER-orig.}
|
|
ep=${b/\./-$PREVER-ethercat.}
|
|
diff -u $op $ep | patch -p1 $e
|
|
git add $o $e
|
|
done
|