mirror of
https://github.com/genodelabs/genode.git
synced 2025-06-19 15:43:56 +00:00
nic: remove usage of deprecated env()
This commit includes changes to the Nic::Session_component interface. We now pass the entire env to the component instead of only ram, rm and the ep because we need the env to open connections from within the Session_component implemenation. So far only the cadence_gem driver needs this, though. Issue #2280.
This commit is contained in:
committed by
Christian Helmuth
parent
e6e1d8c144
commit
15821e32ec
@ -179,12 +179,9 @@ class Usb_nic::Session_component : public Nic::Session_component
|
||||
Session_component(Genode::size_t const tx_buf_size,
|
||||
Genode::size_t const rx_buf_size,
|
||||
Genode::Allocator &rx_block_md_alloc,
|
||||
Genode::Ram_session &ram_session,
|
||||
Genode::Region_map ®ion_map,
|
||||
Genode::Entrypoint &ep,
|
||||
Genode::Env &env,
|
||||
Device *device)
|
||||
: Nic::Session_component(tx_buf_size, rx_buf_size, rx_block_md_alloc,
|
||||
ram_session, region_map, ep),
|
||||
: Nic::Session_component(tx_buf_size, rx_buf_size, rx_block_md_alloc, env),
|
||||
_device(device)
|
||||
{ _device->session(this); }
|
||||
|
||||
@ -258,9 +255,7 @@ class Root : public Root_component
|
||||
|
||||
return new (Root::md_alloc())
|
||||
Usb_nic::Session_component(tx_buf_size, rx_buf_size,
|
||||
Lx::Malloc::mem(),
|
||||
_env.ram(), _env.rm(),
|
||||
_env.ep(), _device);
|
||||
Lx::Malloc::mem(), _env, _device);
|
||||
}
|
||||
|
||||
public:
|
||||
|
@ -90,11 +90,8 @@ class Wifi_session_component : public Nic::Session_component
|
||||
Wifi_session_component(Genode::size_t const tx_buf_size,
|
||||
Genode::size_t const rx_buf_size,
|
||||
Genode::Allocator &rx_block_md_alloc,
|
||||
Genode::Ram_session &ram_session,
|
||||
Genode::Region_map ®ion_map,
|
||||
Genode::Entrypoint &ep, net_device *ndev)
|
||||
: Session_component(tx_buf_size, rx_buf_size, rx_block_md_alloc,
|
||||
ram_session, region_map, ep),
|
||||
Genode::Env &env, net_device *ndev)
|
||||
: Session_component(tx_buf_size, rx_buf_size, rx_block_md_alloc, env),
|
||||
_ndev(ndev)
|
||||
{
|
||||
_ndev->lx_nic_device = this;
|
||||
@ -198,9 +195,7 @@ class Root : public Genode::Root_component<Wifi_session_component,
|
||||
|
||||
session = new (md_alloc())
|
||||
Wifi_session_component(tx_buf_size, rx_buf_size,
|
||||
*md_alloc(),
|
||||
_env.ram(), _env.rm(),
|
||||
_env.ep(), device);
|
||||
*md_alloc(), _env, device);
|
||||
return session;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user