mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 11:41:38 -04:00
[AX.25]: Fix default address and broadcast address initialization.
Only the callsign but not the SSID part of an AX.25 address is ASCII based but Linux by initializes the SSID which should be just a 4-bit number from ASCII anyway. Fix that and convert the code to use a shared constant for both default addresses. While at it, use the same style for null_ax25_address also. Signed-off-by: Ralf Baechle <[email protected]> Signed-off-by: David S. Miller <[email protected]>
This commit is contained in:
parent
e8cc49bb0f
commit
15b1c0e822
10 changed files with 31 additions and 71 deletions
|
|
@ -29,11 +29,20 @@
|
|||
#include <linux/interrupt.h>
|
||||
|
||||
/*
|
||||
* The null address is defined as a callsign of all spaces with an
|
||||
* SSID of zero.
|
||||
* The default broadcast address of an interface is QST-0; the default address
|
||||
* is LINUX-1. The null address is defined as a callsign of all spaces with
|
||||
* an SSID of zero.
|
||||
*/
|
||||
ax25_address null_ax25_address = {{0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x00}};
|
||||
|
||||
const ax25_address ax25_bcast =
|
||||
{{'Q' << 1, 'S' << 1, 'T' << 1, ' ' << 1, ' ' << 1, ' ' << 1, 0 << 1}};
|
||||
const ax25_address ax25_defaddr =
|
||||
{{'L' << 1, 'I' << 1, 'N' << 1, 'U' << 1, 'X' << 1, ' ' << 1, 1 << 1}};
|
||||
const ax25_address null_ax25_address =
|
||||
{{' ' << 1, ' ' << 1, ' ' << 1, ' ' << 1, ' ' << 1, ' ' << 1, 0 << 1}};
|
||||
|
||||
EXPORT_SYMBOL_GPL(ax25_bcast);
|
||||
EXPORT_SYMBOL_GPL(ax25_defaddr);
|
||||
EXPORT_SYMBOL(null_ax25_address);
|
||||
|
||||
/*
|
||||
|
|
|
|||
Loading…
Reference in a new issue