summaryrefslogtreecommitdiffstats
path: root/src/include/shared.h
blob: 2cad391a6e148d7f52a3005d7bdd3d4e8ed8b9d1 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#ifndef SHARED_H
#define SHARED_H

/*
 * To save space in the binary when multiple-driver images are
 * compiled, uninitialised data areas can be shared between drivers.
 * This will typically be used to share statically-allocated receive
 * and transmit buffers between drivers.
 *
 * Use as e.g.
 *
 *  struct {
 *	char	rx_buf[NUM_RX_BUF][RX_BUF_SIZE];
 *	char	tx_buf[TX_BUF_SIZE];
 *  } my_static_data __shared;
 *
 */

#define __shared __asm__ ( "_shared_bss" );

#endif /* SHARED_H */