]> git.saurik.com Git - apple/xnu.git/blame_incremental - bsd/net/net_stubs.c
xnu-4903.241.1.tar.gz
[apple/xnu.git] / bsd / net / net_stubs.c
... / ...
CommitLineData
1/*
2 * Copyright (c) 2012-2018 Apple Inc. All rights reserved.
3 *
4 * @APPLE_OSREFERENCE_LICENSE_HEADER_START@
5 *
6 * This file contains Original Code and/or Modifications of Original Code
7 * as defined in and that are subject to the Apple Public Source License
8 * Version 2.0 (the 'License'). You may not use this file except in
9 * compliance with the License. The rights granted to you under the License
10 * may not be used to create, or enable the creation or redistribution of,
11 * unlawful or unlicensed copies of an Apple operating system, or to
12 * circumvent, violate, or enable the circumvention or violation of, any
13 * terms of an Apple operating system software license agreement.
14 *
15 * Please obtain a copy of the License at
16 * http://www.opensource.apple.com/apsl/ and read it before using this file.
17 *
18 * The Original Code and all software distributed under the License are
19 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
20 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
21 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
22 * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
23 * Please see the License for the specific language governing rights and
24 * limitations under the License.
25 *
26 * @APPLE_OSREFERENCE_LICENSE_HEADER_END@
27 */
28
29#include <kern/debug.h>
30
31#if !NETWORKING
32
33#define STUB(name) \
34 int name(void); \
35 int name(void) \
36 { \
37 panic("stub called in a config with no networking"); \
38 return (0); \
39 }
40
41STUB(bpf_attach);
42STUB(bpf_tap_in);
43STUB(bpf_tap_out);
44STUB(bpfattach);
45STUB(ctl_deregister);
46STUB(ctl_enqueuedata);
47STUB(ctl_enqueuembuf);
48STUB(ctl_enqueuembuf_list);
49STUB(ctl_getenqueuespace);
50STUB(ctl_register);
51STUB(ether_add_proto);
52STUB(ether_check_multi);
53STUB(ether_del_proto);
54STUB(ether_demux);
55STUB(ether_frameout);
56STUB(ether_ioctl);
57STUB(fifo_advlock);
58STUB(fifo_close);
59STUB(fifo_inactive);
60STUB(fifo_ioctl);
61STUB(fifo_lookup);
62STUB(fifo_open);
63STUB(fifo_pathconf);
64STUB(fifo_read);
65STUB(fifo_select);
66STUB(fifo_write);
67STUB(ifaddr_address);
68STUB(ifaddr_address_family);
69STUB(ifaddr_dstaddress);
70STUB(ifaddr_findbestforaddr);
71STUB(ifaddr_ifnet);
72STUB(ifaddr_netmask);
73STUB(ifaddr_reference);
74STUB(ifaddr_release);
75STUB(ifaddr_withaddr);
76STUB(ifaddr_withdstaddr);
77STUB(ifaddr_withnet);
78STUB(ifaddr_withroute);
79STUB(iflt_attach);
80STUB(iflt_detach);
81STUB(ifmaddr_address);
82STUB(ifmaddr_ifnet);
83STUB(ifmaddr_lladdress);
84STUB(ifmaddr_reference);
85STUB(ifmaddr_release);
86STUB(ifnet_add_multicast);
87STUB(ifnet_addrlen);
88STUB(ifnet_allocate);
89STUB(ifnet_allocate_internal);
90STUB(ifnet_attach);
91STUB(ifnet_attach_protocol);
92STUB(ifnet_baudrate);
93STUB(ifnet_capabilities_enabled);
94STUB(ifnet_capabilities_supported);
95STUB(ifnet_detach);
96STUB(ifnet_detach_protocol);
97STUB(ifnet_eflags);
98STUB(ifnet_event);
99STUB(ifnet_family);
100STUB(ifnet_subfamily);
101STUB(ifnet_find_by_name);
102STUB(ifnet_flags);
103STUB(ifnet_free_address_list);
104STUB(ifnet_free_multicast_list);
105STUB(ifnet_get_address_list);
106STUB(ifnet_get_address_list_family);
107STUB(ifnet_get_link_mib_data);
108STUB(ifnet_get_link_mib_data_length);
109STUB(ifnet_get_multicast_list);
110STUB(ifnet_get_service_class_sndq_len);
111STUB(ifnet_get_tso_mtu);
112STUB(ifnet_get_wake_flags);
113STUB(ifnet_hdrlen);
114STUB(ifnet_index);
115STUB(ifnet_input);
116STUB(ifnet_interface_family_find);
117STUB(ifnet_ioctl);
118STUB(ifnet_lastchange);
119STUB(ifnet_list_free);
120STUB(ifnet_list_get);
121STUB(ifnet_lladdr);
122STUB(ifnet_lladdr_copy_bytes);
123STUB(ifnet_llbroadcast_copy_bytes);
124STUB(ifnet_metric);
125STUB(ifnet_mtu);
126STUB(ifnet_name);
127STUB(ifnet_offload);
128STUB(ifnet_output);
129STUB(ifnet_output_raw);
130STUB(ifnet_reference);
131STUB(ifnet_release);
132STUB(ifnet_remove_multicast);
133STUB(ifnet_resolve_multicast);
134STUB(ifnet_set_addrlen);
135STUB(ifnet_set_baudrate);
136STUB(ifnet_set_capabilities_enabled);
137STUB(ifnet_set_capabilities_supported);
138STUB(ifnet_set_delegate);
139STUB(ifnet_set_eflags);
140STUB(ifnet_set_flags);
141STUB(ifnet_set_hdrlen);
142STUB(ifnet_set_link_mib_data);
143STUB(ifnet_set_lladdr);
144STUB(ifnet_set_metric);
145STUB(ifnet_set_mtu);
146STUB(ifnet_set_offload);
147STUB(ifnet_set_promiscuous);
148STUB(ifnet_set_stat);
149STUB(ifnet_set_tso_mtu);
150STUB(ifnet_set_wake_flags);
151STUB(ifnet_softc);
152STUB(ifnet_stat);
153STUB(ifnet_stat_increment);
154STUB(ifnet_stat_increment_in);
155STUB(ifnet_stat_increment_out);
156STUB(ifnet_touch_lastchange);
157STUB(ifnet_type);
158STUB(ifnet_unit);
159STUB(in_cksum);
160STUB(inet_arp_handle_input);
161STUB(inet_arp_init_ifaddr);
162STUB(inet_arp_lookup);
163STUB(ipf_addv4);
164STUB(ipf_addv6);
165STUB(ipf_inject_input);
166STUB(ipf_inject_output);
167STUB(ipf_remove);
168STUB(kev_msg_post);
169STUB(kev_vendor_code_find);
170STUB(mbuf_adj);
171STUB(mbuf_adjustlen);
172STUB(mbuf_align_32);
173STUB(mbuf_alloccluster);
174STUB(mbuf_allocpacket);
175STUB(mbuf_allocpacket_list);
176STUB(mbuf_attachcluster);
177STUB(mbuf_clear_csum_performed);
178STUB(mbuf_clear_csum_requested);
179STUB(mbuf_clear_vlan_tag);
180STUB(mbuf_concatenate);
181STUB(mbuf_copy_pkthdr);
182STUB(mbuf_copyback);
183STUB(mbuf_copydata);
184STUB(mbuf_copym);
185STUB(mbuf_data);
186STUB(mbuf_data_to_physical);
187STUB(mbuf_datastart);
188STUB(mbuf_dup);
189STUB(mbuf_flags);
190STUB(mbuf_free);
191STUB(mbuf_freecluster);
192STUB(mbuf_freem);
193STUB(mbuf_freem_list);
194STUB(mbuf_get);
195STUB(mbuf_get_csum_performed);
196STUB(mbuf_get_csum_requested);
197STUB(mbuf_get_mhlen);
198STUB(mbuf_get_minclsize);
199STUB(mbuf_get_mlen);
200STUB(mbuf_get_traffic_class);
201STUB(mbuf_get_tso_requested);
202STUB(mbuf_get_vlan_tag);
203STUB(mbuf_getcluster);
204STUB(mbuf_gethdr);
205STUB(mbuf_getpacket);
206STUB(mbuf_inbound_modified);
207STUB(mbuf_inet_cksum);
208STUB(mbuf_is_traffic_class_privileged);
209STUB(mbuf_leadingspace);
210STUB(mbuf_len);
211STUB(mbuf_maxlen);
212STUB(mbuf_mclget);
213STUB(mbuf_mclhasreference);
214STUB(mbuf_next);
215STUB(mbuf_nextpkt);
216STUB(mbuf_outbound_finalize);
217STUB(mbuf_pkthdr_adjustlen);
218STUB(mbuf_pkthdr_header);
219STUB(mbuf_pkthdr_len);
220STUB(mbuf_pkthdr_rcvif);
221STUB(mbuf_pkthdr_setheader);
222STUB(mbuf_pkthdr_setlen);
223STUB(mbuf_pkthdr_setrcvif);
224STUB(mbuf_prepend);
225STUB(mbuf_pulldown);
226STUB(mbuf_pullup);
227STUB(mbuf_set_csum_performed);
228STUB(mbuf_set_csum_requested);
229STUB(mbuf_set_traffic_class);
230STUB(mbuf_set_vlan_tag);
231STUB(mbuf_setdata);
232STUB(mbuf_setflags);
233STUB(mbuf_setflags_mask);
234STUB(mbuf_setlen);
235STUB(mbuf_setnext);
236STUB(mbuf_setnextpkt);
237STUB(mbuf_settype);
238STUB(mbuf_split);
239STUB(mbuf_stats);
240STUB(mbuf_tag_allocate);
241STUB(mbuf_tag_find);
242STUB(mbuf_tag_free);
243STUB(mbuf_tag_id_find);
244STUB(mbuf_add_drvaux);
245STUB(mbuf_find_drvaux);
246STUB(mbuf_del_drvaux);
247STUB(mbuf_trailingspace);
248STUB(mbuf_type);
249STUB(mbuf_get_flowid);
250STUB(mbuf_set_flowid);
251STUB(mbuf_get_timestamp);
252STUB(mbuf_set_timestamp);
253STUB(mbuf_get_tx_compl_data);
254STUB(mbuf_set_tx_compl_data);
255STUB(mbuf_get_status);
256STUB(mbuf_set_status);
257STUB(mbuf_get_timestamp_requested);
258STUB(mbuf_set_timestamp_requested);
259STUB(mbuf_register_tx_compl_callback);
260STUB(mbuf_unregister_tx_compl_callback);
261STUB(net_init_add);
262STUB(proto_inject);
263STUB(proto_input);
264STUB(proto_register_plumber);
265STUB(proto_unregister_plumber);
266STUB(sflt_attach);
267STUB(sflt_detach);
268STUB(sflt_register);
269STUB(sflt_unregister);
270STUB(sock_accept);
271STUB(sock_bind);
272STUB(sock_close);
273STUB(sock_connect);
274STUB(sock_connectwait);
275STUB(sock_getpeername);
276STUB(sock_getsockname);
277STUB(sock_getsockopt);
278STUB(sock_gettype);
279STUB(sock_inject_data_in);
280STUB(sock_inject_data_out);
281STUB(sock_ioctl);
282STUB(sock_isconnected);
283STUB(sock_isnonblocking);
284STUB(sock_listen);
285STUB(sock_nointerrupt);
286STUB(sock_receive);
287STUB(sock_receivembuf);
288STUB(sock_send);
289STUB(sock_sendmbuf);
290STUB(sock_setpriv);
291STUB(sock_setsockopt);
292STUB(sock_shutdown);
293STUB(sock_socket);
294STUB(sockopt_copyin);
295STUB(sockopt_copyout);
296STUB(sockopt_direction);
297STUB(sockopt_level);
298STUB(sockopt_name);
299STUB(sockopt_valsize);
300STUB(kev_post_msg);
301STUB(ctl_id_by_name);
302STUB(ctl_name_by_id);
303STUB(ifnet_allocate_extended);
304STUB(ifnet_bandwidths);
305STUB(ifnet_clone_attach);
306STUB(ifnet_clone_detach);
307STUB(ifnet_dequeue);
308STUB(ifnet_dequeue_multi);
309STUB(ifnet_dequeue_multi_bytes);
310STUB(ifnet_dequeue_service_class);
311STUB(ifnet_dequeue_service_class_multi);
312STUB(ifnet_enqueue);
313STUB(ifnet_get_delegate);
314STUB(ifnet_get_inuse_address_list);
315STUB(ifnet_get_local_ports);
316STUB(ifnet_get_local_ports_extended);
317STUB(ifnet_get_rcvq_maxlen);
318STUB(ifnet_get_sndq_len);
319STUB(ifnet_get_sndq_maxlen);
320STUB(ifnet_idle_flags);
321STUB(ifnet_inet6_defrouter_llreachinfo);
322STUB(ifnet_inet_defrouter_llreachinfo);
323STUB(ifnet_input_extended);
324STUB(ifnet_latencies);
325STUB(ifnet_link_quality);
326STUB(ifnet_notice_master_elected);
327STUB(ifnet_notice_node_absence);
328STUB(ifnet_notice_node_presence);
329STUB(ifnet_poll_params);
330STUB(ifnet_purge);
331STUB(ifnet_report_issues);
332STUB(ifnet_set_bandwidths);
333STUB(ifnet_set_idle_flags);
334STUB(ifnet_set_latencies);
335STUB(ifnet_set_link_quality);
336STUB(ifnet_set_output_sched_model);
337STUB(ifnet_set_poll_params);
338STUB(ifnet_set_rcvq_maxlen);
339STUB(ifnet_set_sndq_maxlen);
340STUB(ifnet_start);
341STUB(ifnet_tx_compl_status);
342STUB(ifnet_tx_compl);
343STUB(ifnet_flowid);
344STUB(ifnet_enable_output);
345STUB(ifnet_disable_output);
346STUB(ifnet_get_keepalive_offload_frames);
347STUB(ifnet_link_status_report);
348STUB(ifnet_set_fastlane_capable);
349STUB(ifnet_get_fastlane_capable);
350STUB(ifnet_get_unsent_bytes);
351STUB(ifnet_get_buffer_status);
352STUB(ifnet_normalise_unsent_data);
353STUB(ifnet_set_low_power_mode);
354STUB(in6_localaddr);
355STUB(in_localaddr);
356STUB(in6addr_local);
357STUB(inaddr_local);
358STUB(inp_clear_INP_INADDR_ANY);
359STUB(ip_gre_output);
360STUB(m_cat);
361STUB(m_free);
362STUB(m_freem);
363STUB(m_get);
364STUB(m_gethdr);
365STUB(m_mtod);
366STUB(m_prepend_2);
367STUB(m_pullup);
368STUB(m_split);
369STUB(mbuf_get_driver_scratch);
370STUB(mbuf_get_unsent_data_bytes);
371STUB(mbuf_get_buffer_status);
372STUB(mbuf_pkt_new_flow);
373STUB(mbuf_last_pkt);
374STUB(mbuf_get_priority);
375STUB(mbuf_get_service_class);
376STUB(mbuf_get_service_class_index);
377STUB(mbuf_get_service_class_max_count);
378STUB(mbuf_get_traffic_class_index);
379STUB(mbuf_get_traffic_class_max_count);
380STUB(mbuf_is_service_class_privileged);
381STUB(mbuf_pkthdr_aux_flags);
382STUB(mcl_to_paddr);
383STUB(net_add_domain);
384STUB(net_add_domain_old);
385STUB(net_add_proto);
386STUB(net_add_proto_old);
387STUB(net_del_domain);
388STUB(net_del_domain_old);
389STUB(net_del_proto);
390STUB(net_del_proto_old);
391STUB(pffinddomain);
392STUB(pffinddomain_old);
393STUB(pffindproto);
394STUB(pffindproto_old);
395STUB(pru_abort_notsupp);
396STUB(pru_accept_notsupp);
397STUB(pru_bind_notsupp);
398STUB(pru_connect2_notsupp);
399STUB(pru_connect_notsupp);
400STUB(pru_disconnect_notsupp);
401STUB(pru_listen_notsupp);
402STUB(pru_peeraddr_notsupp);
403STUB(pru_rcvd_notsupp);
404STUB(pru_rcvoob_notsupp);
405STUB(pru_send_notsupp);
406STUB(pru_send_list_notsupp);
407STUB(pru_sense_null);
408STUB(pru_shutdown_notsupp);
409STUB(pru_sockaddr_notsupp);
410STUB(pru_sopoll_notsupp);
411STUB(sbappendaddr);
412STUB(sbappendrecord);
413STUB(sbflush);
414STUB(sbspace);
415STUB(soabort);
416STUB(socantrcvmore);
417STUB(socantsendmore);
418STUB(sock_getlistener);
419STUB(sock_gettclassopt);
420STUB(sock_release);
421STUB(sock_retain);
422STUB(sock_settclassopt);
423STUB(sock_catchevents);
424STUB(sock_setupcall);
425STUB(sock_setupcalls);
426STUB(sodisconnect);
427STUB(sofree);
428STUB(sofreelastref);
429STUB(soisconnected);
430STUB(soisconnecting);
431STUB(soisdisconnected);
432STUB(soisdisconnecting);
433STUB(sonewconn);
434STUB(sooptcopyin);
435STUB(sooptcopyout);
436STUB(sopoll);
437STUB(soreceive);
438STUB(soreceive_list);
439STUB(soreserve);
440STUB(sorwakeup);
441STUB(sosend);
442STUB(sosend_list);
443STUB(utun_ctl_disable_crypto_dtls);
444STUB(utun_ctl_register_dtls);
445STUB(utun_pkt_dtls_input);
446STUB(dlil_resolve_multi);
447STUB(inet_cksum_simple);
448STUB(arp_ip_handle_input);
449STUB(arp_ifinit);
450STUB(arp_lookup_ip);
451STUB(ip_gre_register_input);
452STUB(sock_iskernel);
453STUB(iflt_attach_internal);
454STUB(ipf_addv4_internal);
455STUB(ipf_addv6_internal);
456STUB(sflt_register_internal);
457STUB(sock_accept_internal);
458STUB(sock_socket_internal);
459#undef STUB
460
461/*
462 * Called from vm_pageout.c. Nothing to be done when there's no networking.
463 */
464void mbuf_drain(boolean_t);
465void mbuf_drain(boolean_t)
466{
467 return;
468}
469
470#endif /* !NETWORKING */