Lines Matching refs:Port

63 // * Port::lock: Protects all Port members save team_link, hash_link, lock and
66 // Port::state ensures atomicity by providing a linearization point for adding
72 // * To make insertion and removal linearizable, Port::state was added. It is
75 // Port::kActive.
77 // First, logical deletion happens and sets Port::state to Port::kDeleted.
82 // and only then sets port to Port::kActive.
83 // This creates a linearization point at the atomic update of Port::state,
111 struct Port : public KernelReferenceable {
119 Port* hash_link;
122 Port* name_hash_link;
136 Port(team_id owner, int32 queueLength, const char* name)
154 virtual ~Port()
166 typedef Port ValueType;
173 size_t Hash(Port* value) const
178 bool Compare(port_id key, Port* value) const
183 Port*& GetLink(Port* value) const
194 typedef Port ValueType;
210 size_t Hash(Port* value) const
218 bool Compare(const char* key, Port* value) const
223 Port*& GetLink(Port* value) const
250 Create(Port* port)
278 Delete(Port* port)
297 Read(const BReference<Port>& portRef, int32 code, ssize_t result)
368 Info(const BReference<Port>& portRef, int32 code, ssize_t result)
408 OwnerChange(Port* port, team_id newOwner, status_t status)
521 Port* port = it.Next();) {
537 _dump_port_info(Port* port)
576 _dump_port_info((Port*)parse_expression(argv[2]));
585 Port* port = sPorts.Lookup(num);
586 if (port == NULL || port->state != Port::kActive) {
598 Port* port = it.Next();) {
619 notify_port_select_events(Port* port, uint16 events)
626 static BReference<Port>
630 BReference<Port> portRef;
637 if (portRef != NULL && portRef->state == Port::kActive) {
647 static BReference<Port>
651 BReference<Port> portRef;
662 is_port_closed(Port* port)
680 /*! Port must be locked. */
683 port_message** _message, Port& port)
720 BReference<Port> newPortRef = get_locked_port(portID);
757 fill_port_info(Port* port, port_info* info, size_t size)
795 uninit_port(Port* port)
815 delete_port_logical(Port* port)
820 Port::kDeleted, Port::kActive);
824 case Port::kActive:
828 case Port::kDeleted:
834 case Port::kUnused:
835 // Port is still being created, retry
839 // Port state got corrupted somehow
864 Port* port = (Port*)list_get_first_item(&team->port_list);
869 Port* nextPort = (Port*)list_get_next_item(&team->port_list, port);
885 for (Port* port = (Port*)list_get_first_item(&deletionList);
887 port = (Port*)list_get_next_item(&deletionList, port)) {
897 while (Port* port = (Port*)list_remove_head_item(&deletionList)) {
925 Port* port = (Port*)0;
993 BReference<Port> port;
995 Port* newPort = new(std::nothrow) Port(team_get_current_team_id(),
1045 Port::kActive, Port::kUnused);
1048 if (oldState != Port::kUnused) {
1050 panic("Port state was modified during creation!\n");
1069 BReference<Port> portRef = get_locked_port(id);
1098 BReference<Port> portRef = get_port(id);
1148 BReference<Port> portRef = get_locked_port(id);
1196 BReference<Port> portRef = get_locked_port(id);
1226 Port* port = sPortsByName.Lookup(name);
1230 if (port != NULL && port->state == Port::kActive)
1248 BReference<Port> portRef = get_locked_port(id);
1286 Port* port = (Port*)list_get_first_item(&team->port_list);
1294 port = (Port*)list_get_next_item(&team->port_list, port);
1301 BReference<Port> portRef = port;
1342 BReference<Port> portRef = get_locked_port(id);
1372 BReference<Port> newPortRef = get_locked_port(id);
1415 BReference<Port> portRef = get_locked_port(id);
1451 BReference<Port> portRef = get_locked_port(id);
1476 BReference<Port> newPortRef = get_locked_port(id);
1580 BReference<Port> portRef = get_locked_port(id);
1607 BReference<Port> newPortRef = get_locked_port(id);
1704 BReference<Port> portRef = get_locked_port(id);
1731 if (portRef->state == Port::kActive) {
1736 // Port was already deleted. We haven't changed anything yet so