mirror of
https://github.com/ipxe/ipxe
synced 2026-04-16 03:00:10 +03:00
gcc is rather over-aggressive about optimising out static data structures
even when __atribute__ (( unused )) is correctly set...
This commit is contained in:
+1
-1
@@ -355,7 +355,7 @@ static int dns_resolv ( struct in_addr *addr, const char *name ) {
|
||||
}
|
||||
}
|
||||
|
||||
static struct resolver dns_resolver __resolver = {
|
||||
struct resolver dns_resolver __resolver = {
|
||||
.name = "DNS",
|
||||
.resolv = dns_resolv,
|
||||
};
|
||||
|
||||
+1
-1
@@ -166,7 +166,7 @@ static int http ( char *url, struct sockaddr_in *server __unused,
|
||||
return 1;
|
||||
}
|
||||
|
||||
static struct protocol http_protocol __protocol = {
|
||||
struct protocol http_protocol __protocol = {
|
||||
.name = "http",
|
||||
.default_port = 80,
|
||||
.load = http,
|
||||
|
||||
+1
-1
@@ -112,7 +112,7 @@ static void process_igmp ( unsigned long now, unsigned short ptype __unused,
|
||||
}
|
||||
}
|
||||
|
||||
static struct background igmp_background __background = {
|
||||
struct background igmp_background __background = {
|
||||
.send = send_igmp_reports,
|
||||
.process = process_igmp,
|
||||
};
|
||||
|
||||
+1
-1
@@ -610,7 +610,7 @@ nfssymlink:
|
||||
|
||||
INIT_FN ( INIT_RPC, rpc_init, nfs_reset, nfs_reset );
|
||||
|
||||
static struct protocol nfs_protocol __protocol = {
|
||||
struct protocol nfs_protocol __protocol = {
|
||||
.name = "nfs",
|
||||
.default_port = SUNRPC_PORT,
|
||||
.load = nfs,
|
||||
|
||||
+1
-1
@@ -100,7 +100,7 @@ static int nmb_resolv ( struct in_addr *addr, const char *name ) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
static struct resolver nmb_resolver __resolver = {
|
||||
struct resolver nmb_resolver __resolver = {
|
||||
.name = "NMB",
|
||||
.resolv = nmb_resolv,
|
||||
};
|
||||
|
||||
+1
-1
@@ -534,7 +534,7 @@ static int url_slam ( char *url __unused, struct sockaddr_in *server,
|
||||
return proto_slam(&info);
|
||||
}
|
||||
|
||||
static struct protocol slam_protocol __protocol = {
|
||||
struct protocol slam_protocol __protocol = {
|
||||
.name = "x-slam",
|
||||
.default_port = SLAM_PORT,
|
||||
.load = url_slam,
|
||||
|
||||
Reference in New Issue
Block a user