Andriy Gapon
b7d28b2e0b
bus_add_child: add specialized default implementation that calls panic
...
If a kobj method doesn't have any explicitly provided default
implementation, then it is auto-assigned kobj_error_method.
kobj_error_method is proper only for methods that return error code,
because it just returns ENXIO.
So, in the case of unimplemented bus_add_child caller would get
(device_t)ENXIO as a return value, which would cause the mistake to go
unnoticed, because return value is typically checked for NULL.
Thus, a specialized null_add_child is added. It would have sufficied
for correctness to return NULL, but this type of mistake was deemed to
be rare and serious enough to call panic instead.
Watch out for this kind of problem with other kobj methods.
Suggested by: jhb, imp
MFC after: 2 weeks
2010-09-13 08:34:20 +00:00
..
2010-09-13 08:34:20 +00:00
2010-05-23 18:32:02 +00:00
2010-08-17 08:55:45 +00:00
2010-07-27 17:31:03 +00:00
2010-08-09 14:48:31 +00:00
2010-08-30 14:26:02 +00:00
2010-06-21 09:55:56 +00:00
2010-04-26 13:48:22 +00:00
2010-09-13 07:25:35 +00:00
2010-09-13 07:25:35 +00:00
2009-02-26 13:00:13 +00:00
2010-08-06 09:44:01 +00:00
2010-08-09 14:48:31 +00:00
2010-06-30 18:03:42 +00:00
2010-07-23 16:46:42 +00:00
2009-10-26 18:32:06 +00:00
2010-04-23 14:32:58 +00:00
2010-08-22 11:09:53 +00:00
2010-01-10 22:34:18 +00:00
2010-09-13 07:25:35 +00:00
2010-03-30 18:31:55 +00:00
2010-08-30 16:30:18 +00:00
2010-08-22 11:18:57 +00:00
2010-01-07 21:01:37 +00:00
2010-09-09 09:58:05 +00:00
2010-04-30 03:10:53 +00:00
2009-11-03 16:46:52 +00:00
2010-06-10 16:14:05 +00:00
2010-09-10 21:45:42 +00:00
2010-05-21 17:14:36 +00:00
2010-07-21 10:14:04 +00:00
2010-08-19 16:38:58 +00:00
2009-11-17 21:56:12 +00:00
2010-08-20 19:46:50 +00:00
2009-06-25 18:54:56 +00:00
2009-05-26 20:28:22 +00:00
2010-09-09 18:33:46 +00:00
2010-06-21 09:55:56 +00:00
2010-07-22 09:13:49 +00:00
2010-06-21 09:55:56 +00:00
2008-10-23 20:26:15 +00:00
2010-05-11 18:24:22 +00:00
2010-04-29 09:18:36 +00:00
2009-05-29 10:52:37 +00:00
2009-08-15 23:07:43 +00:00
2010-08-22 11:18:57 +00:00
2010-08-22 11:18:57 +00:00
2010-07-18 20:57:53 +00:00
2010-07-18 20:57:53 +00:00
2010-09-01 19:50:03 +00:00
2010-03-24 19:21:26 +00:00
2010-06-21 09:55:56 +00:00
2010-04-20 12:22:06 +00:00
2010-09-10 16:42:16 +00:00
2010-06-11 18:46:34 +00:00
2010-06-08 16:17:47 +00:00
2009-07-14 22:52:46 +00:00
2010-06-28 18:06:46 +00:00
2010-09-09 18:33:46 +00:00
2010-09-13 07:25:35 +00:00
2010-08-24 07:29:55 +00:00
2010-07-15 20:24:37 +00:00
2009-04-10 10:52:19 +00:00
2010-09-13 07:25:35 +00:00
2010-08-25 03:14:32 +00:00
2009-08-23 20:40:19 +00:00
2009-05-29 21:27:12 +00:00
2010-03-03 21:46:51 +00:00
2010-07-23 17:07:51 +00:00
2009-07-14 22:48:30 +00:00
2009-06-11 17:05:45 +00:00
2008-12-01 14:34:42 +00:00
2010-08-23 06:22:35 +00:00
2010-06-28 18:06:46 +00:00
2010-06-02 09:59:05 +00:00
2010-09-13 07:25:35 +00:00
2010-09-13 07:25:35 +00:00
2009-10-20 16:36:51 +00:00
2010-08-30 16:30:18 +00:00
2010-08-30 16:30:18 +00:00
2010-08-12 19:50:40 +00:00
2008-10-23 15:53:51 +00:00
2010-05-05 20:39:02 +00:00
2010-09-10 11:19:03 +00:00
2010-06-21 09:55:56 +00:00
2010-09-02 19:40:28 +00:00
2010-03-19 19:51:03 +00:00
2010-06-21 09:55:56 +00:00
2010-03-07 22:37:35 +00:00
2010-02-21 19:53:33 +00:00
2010-06-11 19:27:21 +00:00
2009-02-03 07:54:42 +00:00
2010-09-09 18:33:46 +00:00
2009-11-03 21:06:19 +00:00
2010-06-21 09:55:56 +00:00
2010-06-21 09:55:56 +00:00
2010-08-06 15:04:40 +00:00
2010-06-11 18:46:34 +00:00
2010-07-12 15:32:45 +00:00
2010-07-18 20:57:53 +00:00
2009-05-19 14:08:21 +00:00
2010-08-12 17:17:05 +00:00
2010-09-11 19:42:50 +00:00
2009-08-21 02:59:07 +00:00
2010-09-09 18:33:46 +00:00
2010-08-09 00:23:57 +00:00
2009-06-24 12:06:15 +00:00
2010-08-28 08:38:03 +00:00
2010-08-22 11:30:49 +00:00
2010-01-09 01:46:38 +00:00
2010-05-08 20:34:01 +00:00
2010-07-09 10:57:55 +00:00
2010-09-09 18:33:46 +00:00
2010-08-28 17:42:08 +00:00
2010-05-08 23:01:47 +00:00
2010-07-04 11:48:30 +00:00
2010-06-29 20:44:19 +00:00
2010-08-30 14:26:02 +00:00
2010-08-30 14:24:44 +00:00
2010-08-30 14:26:02 +00:00
2010-03-19 11:01:51 +00:00
2010-03-19 11:04:42 +00:00
2010-06-11 09:27:33 +00:00
2010-06-29 01:04:24 +00:00
2010-01-04 20:59:52 +00:00
2009-05-17 16:17:48 +00:00
2010-02-07 15:42:15 +00:00
2010-02-07 15:42:15 +00:00
2010-04-08 08:58:18 +00:00
2009-10-17 08:59:41 +00:00
2010-08-06 09:42:15 +00:00
2009-12-28 22:56:30 +00:00
2010-05-06 17:43:41 +00:00
2009-05-26 09:19:21 +00:00
2009-08-24 10:03:41 +00:00
2010-06-21 09:55:56 +00:00
2010-07-18 20:57:53 +00:00
2010-06-21 09:55:56 +00:00
2010-06-02 09:59:05 +00:00
2010-06-02 15:46:37 +00:00
2009-06-22 21:46:40 +00:00
2010-08-07 17:57:58 +00:00
2010-09-05 20:13:07 +00:00
2010-07-22 05:42:29 +00:00
2010-06-03 13:45:27 +00:00
2010-03-19 11:11:34 +00:00
2010-08-12 08:36:23 +00:00
2010-08-22 11:18:57 +00:00
2010-08-09 22:56:10 +00:00
2010-08-25 18:09:51 +00:00
2009-09-28 18:07:16 +00:00
2010-07-18 20:57:53 +00:00
2009-02-06 14:51:32 +00:00
2010-08-22 11:18:57 +00:00
2010-09-11 13:06:06 +00:00
2010-09-11 13:06:06 +00:00
2010-08-22 11:18:57 +00:00
2010-06-26 21:44:45 +00:00
2010-05-12 21:24:46 +00:00