233 /*
234 * device operations
235 */
236 static int ural_attach(dev_info_t *, ddi_attach_cmd_t);
237 static int ural_detach(dev_info_t *, ddi_detach_cmd_t);
238
239 /*
240 * Module Loading Data & Entry Points
241 */
242 DDI_DEFINE_STREAM_OPS(ural_dev_ops, nulldev, nulldev, ural_attach,
243 ural_detach, nodev, NULL, D_MP, NULL, ddi_quiesce_not_needed);
244
245 static struct modldrv ural_modldrv = {
246 &mod_driverops, /* Type of module. This one is a driver */
247 "ural driver v1.4", /* short description */
248 &ural_dev_ops /* driver specific ops */
249 };
250
251 static struct modlinkage modlinkage = {
252 MODREV_1,
253 (void *)&ural_modldrv,
254 NULL
255 };
256
257 static int ural_m_stat(void *, uint_t, uint64_t *);
258 static int ural_m_start(void *);
259 static void ural_m_stop(void *);
260 static int ural_m_promisc(void *, boolean_t);
261 static int ural_m_multicst(void *, boolean_t, const uint8_t *);
262 static int ural_m_unicst(void *, const uint8_t *);
263 static mblk_t *ural_m_tx(void *, mblk_t *);
264 static void ural_m_ioctl(void *, queue_t *, mblk_t *);
265 static int ural_m_setprop(void *, const char *, mac_prop_id_t,
266 uint_t, const void *);
267 static int ural_m_getprop(void *, const char *, mac_prop_id_t,
268 uint_t, void *);
269 static void ural_m_propinfo(void *, const char *, mac_prop_id_t,
270 mac_prop_info_handle_t);
271
272 static mac_callbacks_t ural_m_callbacks = {
273 MC_IOCTL | MC_SETPROP | MC_GETPROP | MC_PROPINFO,
274 ural_m_stat,
|
233 /*
234 * device operations
235 */
236 static int ural_attach(dev_info_t *, ddi_attach_cmd_t);
237 static int ural_detach(dev_info_t *, ddi_detach_cmd_t);
238
239 /*
240 * Module Loading Data & Entry Points
241 */
242 DDI_DEFINE_STREAM_OPS(ural_dev_ops, nulldev, nulldev, ural_attach,
243 ural_detach, nodev, NULL, D_MP, NULL, ddi_quiesce_not_needed);
244
245 static struct modldrv ural_modldrv = {
246 &mod_driverops, /* Type of module. This one is a driver */
247 "ural driver v1.4", /* short description */
248 &ural_dev_ops /* driver specific ops */
249 };
250
251 static struct modlinkage modlinkage = {
252 MODREV_1,
253 { (void *)&ural_modldrv, NULL }
254 };
255
256 static int ural_m_stat(void *, uint_t, uint64_t *);
257 static int ural_m_start(void *);
258 static void ural_m_stop(void *);
259 static int ural_m_promisc(void *, boolean_t);
260 static int ural_m_multicst(void *, boolean_t, const uint8_t *);
261 static int ural_m_unicst(void *, const uint8_t *);
262 static mblk_t *ural_m_tx(void *, mblk_t *);
263 static void ural_m_ioctl(void *, queue_t *, mblk_t *);
264 static int ural_m_setprop(void *, const char *, mac_prop_id_t,
265 uint_t, const void *);
266 static int ural_m_getprop(void *, const char *, mac_prop_id_t,
267 uint_t, void *);
268 static void ural_m_propinfo(void *, const char *, mac_prop_id_t,
269 mac_prop_info_handle_t);
270
271 static mac_callbacks_t ural_m_callbacks = {
272 MC_IOCTL | MC_SETPROP | MC_GETPROP | MC_PROPINFO,
273 ural_m_stat,
|