Граф коммитов

2702 Коммитов

Автор SHA1 Сообщение Дата
Thomas Zimmermann 7c1faa403c Bug 1168806: Configurable consumer thread for socket IPC classes, r=kmachulis
The consumer thread handles socket creation, destruction, and
data processing for socket IPC. Traditionally this has been
done on the main thread.

This patch extends the socket IPC classes to support arbitrary
consumer threads. The thread is configured when establishing a
connection, and performs all of the above operations until the
socket is closed.
2015-06-02 10:01:57 +02:00
Thomas Zimmermann 100bf3cb9c Bug 1168806: Configurable I/O thread for socket IPC classes, r=kmachulis
The I/O thread sends and receives data on a file descriptor. This
has traditionally been performed on a single I/O thread.

This patch extends the socket IPC classes to support arbitrary I/O
threads. The thread is configured when a connection is established
and used until the socket gets closed.
2015-06-02 10:01:57 +02:00
Randell Jesup 556337fa7c Bug 1109338: Part 2: Sharing UDPSocket between PNecko and PBackground r=bent 2015-05-29 10:14:14 -04:00
Botond Ballo e517cc3f1e Bug 1166583 - Move chromium's MakeTuple function into namespace 'base' to avoid conflicts with mozilla::MakeTuple. r=froydnj
--HG--
extra : source : 2258a91d5781efe8e1d5f92f64ff173412705274
2015-05-09 21:09:40 -05:00
Nicholas Nethercote 5eb694dc49 Bug 1164374 - Use StaticMutex in BrowserProcessSubThread. r=froydnj.
This removes a static constructor.

--HG--
extra : rebase_source : 4ed2f222517263616ffd15719f254b9715887681
2015-05-13 01:59:52 -07:00
Birunthan Mohanathas 180b572edb Bug 968520 - Add mozilla::fallible to FallibleTArray::AppendElement calls. r=froydnj 2015-05-28 11:07:44 -07:00
Birunthan Mohanathas 470bd9148f Bug 968520 - Add mozilla::fallible to FallibleTArray::AppendElements calls. r=froydnj 2015-05-28 11:07:43 -07:00
Ryan VanderMeulen 683b08ae37 Merge m-c to inbound. a=merge 2015-05-28 10:20:38 -04:00
Ryan VanderMeulen a232cd6cae Merge inbound to m-c. a=merge 2015-05-28 10:03:07 -04:00
Wes Kocher 0801283501 Merge m-c to b2ginbound, a=merge CLOSED TREE 2015-05-27 17:23:19 -07:00
Thomas Zimmermann 621428ac80 Bug 1167210: Replace |union sockaddr_any| with |struct sockaddr_storage|, r=kmachulis
Both types, |union sockaddr_any| and |struct sockaddr_storage|, provide
a sockaddr type that can hold any address. The latter is standardized by
POSIX, so we prefer it.
2015-05-27 13:49:07 +02:00
Thomas Zimmermann f6aa576d06 Bug 1167207: Remove |BluetoothDaemonChannel|, r=shuang
This patch integrates the functionality of |BluetoothDaemonChannel|
into |BluetoothDaemonConnection|. All users are adapted, the former
class is removed.
2015-05-26 18:29:02 +02:00
Thomas Zimmermann 3d2eac5a25 Bug 1167207: Add |BluetoothDaemonConnectionConsumer|, r=shuang
Instances of |BluetoothDaemonConnectionConsumer| handle socket events
for |BluetoothDaemonConnection|.
2015-05-26 18:29:01 +02:00
Wes Kocher fd401f9e9b Merge m-c to inbound, a=merge CLOSED TREE 2015-05-26 16:25:11 -07:00
Botond Ballo 2e2a504271 Bug 1119980 - Use 'snprintf' instead of 'sprintf' to avoid a warning on Lollipop-based builds. r=froydnj
--HG--
extra : source : 7468f9a3aa03520a29e138d4df431f0b5d90967c
2015-05-26 14:33:55 -04:00
Thomas Zimmermann f9ce4741fd Bug 1166638: Use |ListenSocketConsumer| in |ListenSocket|, r=kmachulis, dlee, chucklee, shuang
This patch converts |ListenSocket| to forward events to an instance
of |ListenSocketConsumer|. All users are converted and the related
listener and consumer classes are removed.
2015-05-26 13:24:20 +02:00
Thomas Zimmermann 636ed53a74 Bug 1166638: Add |ListenSocketConsumer|, r=kmachulis
|ListenSocketConsumer| receives events from a listening socket. It
unifies all existing consumer and listener classes of the socket I/O
users.
2015-05-26 13:24:20 +02:00
Thomas Zimmermann d24dddee86 Bug 1166638: Use |StreamSocketConsumer| in |StreamSocket|, r=kmachulis, dlee, chucklee, htsai
This patch converts |StreamSocket| to forward events and data to an
instance of |StreamSocketConsumer|. All users are converted and the
related listener and consumer classes are removed.
2015-05-26 13:24:20 +02:00
Thomas Zimmermann 5a8451674e Bug 1166638: Add |StreamSocketConsumer|, r=kmachulis
|StreamSocketConsumer| receives events and data from a stream
socket. It unifies all existing consumer and listener classes
of the socket I/O users.
2015-05-26 13:24:19 +02:00
Lee Salzman 98b5eb1f42 Bug 1168843 - use thread-safe refcounting for shared memory surfaces to avoid shutdown crashes. r=jmuizelaar
--HG--
extra : rebase_source : d12172cf16ee64e72882cae2f72a1bbf74ff464f
2015-05-27 11:20:26 -04:00
Michael Layzell 4dc87f0a9b Bug 1167396 - Make ProtocolCloneContext::mContentParent a smart pointer. r=bent 2015-05-22 10:10:00 -04:00
Phil Ringnalda 198fda1fe8 Back out 7842a044a183 (bug 1167431) for widespread bustage
CLOSED TREE
2015-05-22 18:53:41 -07:00
Ben Turner a53a3243ec Bug 1167431 - 'Properly clean up actors whose RecvFooConstructor method returns false', r=billm. 2015-05-22 16:10:02 -07:00
Cervantes Yu 686678cef7 Bug 1151672 - Part 2: Block PHal::Msg_NotifyNetworkChange__ID to the Nuwa process after it is ready. r=khuey 2015-05-22 15:08:20 +08:00
Thomas Zimmermann 70a7cf2bf2 Bug 1164417: Add |ConnectionOrientedSocket::PrepareAccept| for accepting socket connections, r=kmachulis
With this patch, stream and listening sockets handle the setup of
accepted sockets internally. Sub-classes of |StreamSocket| don't
have to overload StreamSocket's |GetIO| any longer.
2015-05-21 13:34:37 +02:00
Thomas Zimmermann 38232bed0f Bug 1164417: Store PDU consumer in |BluetoothDaemonConnection|, r=kmachulis 2015-05-21 13:34:37 +02:00
Thomas Zimmermann 5689bc8e15 Bug 1164417: Add |UnixSocketConnector::Duplicate|, r=kmachulis
The new method |UnixSocketConnector::Duplicate| allows a socket
connector to duplicate itself. Listening sockets will used this
feature to create socket connectors for accepted connections.
2015-05-21 13:34:37 +02:00
Carsten "Tomcat" Book 12f69af823 merge mozilla-inbound to mozilla-central a=merge 2015-05-20 15:52:31 +02:00
Carsten "Tomcat" Book f778f94014 merge b2g-inbound to mozilla-central a=merge
--HG--
extra : rebase_source : ff7d4c568ac183205e8a1180489f87e40521922b
2015-05-20 15:31:22 +02:00
Thomas Zimmermann 2ef09c7cbf Bug 1164425: Cleanup interfaces of |BluetoothDaemonConnection|, r=shuang
Bluetooth never actively opens a connection to the daemon, so this
patch removes the connect functionality.
2015-05-20 10:50:43 +02:00
Thomas Zimmermann 840f154d6b Bug 1164425: Cleanup interfaces of |ListenSocket|, r=kmachulis
This patch removes |ListenSocket::GetSocketAddr|, which is unused
and not thread-safe. The |Listen| methods now return error codes.
2015-05-20 10:50:43 +02:00
Thomas Zimmermann d21bc736cb Bug 1164425: Cleanup interfaces of |StreamSocket|, r=kmachulis
This patch cleans up the interface of |StreamSocket|. All arguments
that contain protocol parameters are removed from |Connect|. They are
stored in the connector class. |Connect| now returns error codes. The
method |GetSocketAddr| is unused and not thread-safe and therefore
removed. The method |SendSocketData| for strings is unused and removed.
2015-05-20 10:50:43 +02:00
Thomas Zimmermann 1237cad18c Bug 1164425: Rename |SocketBase::CloseSocket| to |SocketBase::Close|, r=kmachulis 2015-05-20 10:50:43 +02:00
Carsten "Tomcat" Book 1aa07d706a Backed out changeset 1e93024c9fec (bug 1164425) for bustage 2015-05-20 10:31:55 +02:00
Carsten "Tomcat" Book f0d911f0ec Backed out changeset 2fd186d1a288 (bug 1164425) 2015-05-20 10:31:09 +02:00
Carsten "Tomcat" Book 1a15bd1430 Backed out changeset 17bd0777339a (bug 1164425) 2015-05-20 10:30:55 +02:00
Carsten "Tomcat" Book d61d111555 Backed out changeset 97ccb9e0cefb (bug 1164425) 2015-05-20 10:30:41 +02:00
Thomas Zimmermann 63fb13df1f Bug 1164425: Cleanup interfaces of |BluetoothDaemonConnection|, r=shuang
Bluetooth never actively opens a connection to the daemon, so this
patch removes the connect functionality.
2015-05-20 09:54:27 +02:00
Thomas Zimmermann 6a46c5c7cf Bug 1164425: Cleanup interfaces of |ListenSocket|, r=kmachulis
This patch removes |ListenSocket::GetSocketAddr|, which is unused
and not thread-safe. The |Listen| methods now return error codes.
2015-05-20 09:54:27 +02:00
Thomas Zimmermann a3afbdf88b Bug 1164425: Cleanup interfaces of |StreamSocket|, r=kmachulis
This patch cleans up the interface of |StreamSocket|. All arguments
that contain protocol parameters are removed from |Connect|. They are
stored in the connector class. |Connect| now returns error codes. The
method |GetSocketAddr| is unused and not thread-safe and therefore
removed. The method |SendSocketData| for strings is unused and removed.
2015-05-20 09:54:27 +02:00
Thomas Zimmermann 533d048a4b Bug 1164425: Rename |SocketBase::CloseSocket| to |SocketBase::Close|, r=kmachulis 2015-05-20 09:54:27 +02:00
Wes Kocher 53d1e1a9e5 Merge b2ginbound to central, a=merge 2015-05-19 16:42:57 -07:00
Thomas Zimmermann a4face3b55 Bug 1161020: Remove old interface and implementation from socket-connector classes, r=kmachulis 2015-05-19 13:28:46 +02:00
Thomas Zimmermann cd0d102a9b Bug 1161020: Use new socket-connector interface in socket classes, r=kmachulis
This patch converts the socket I/O classes to use the new interface
of the socket-connector classes. All sockets are now created and set
up by a socket connector.
2015-05-19 13:28:46 +02:00
Thomas Zimmermann a611698da4 Bug 1161020: Implement new socket-connector interface for key store, r=chucklee
This patch moves |KeyStoreConnector| into its own file and implements
the new socket-connector interface.
2015-05-19 13:28:46 +02:00
Thomas Zimmermann 19225eac97 Bug 1161020: Implement new socket-connector interface for RIL, r=htsai
This patch moves |RilConnector| into its own file and implements
the new socket-connector interface.
2015-05-19 13:28:46 +02:00
Thomas Zimmermann 62b1926054 Bug 1161020: Implement new socket-connector interface for NFC, r=allstars.chh
This patch moves |NfcConnector| into its own file and implements
the new socket-connector interface.
2015-05-19 13:28:46 +02:00
Thomas Zimmermann 874110779f Bug 1161020: Added clean interface to |UnixSocketConnector|, r=kmachulis
The current interface of |UnixSocketConnector| doesn't follow any design
and is not easily understandable.

This patch adds a new interface to the class. The new interface provides
a method for each of the following operations:

  * converting an address to a human-readable string,
  * creating a listening socket,
  * creating a stream socket, and
  * accepting a stream socket from a listening socket.

All arguments are stored in the connector class, so that connect and
listen methods of the socket classes don't require protocol-specific
arguments. All socket parameters are set within the connector class,
so each connector class can now select parameters individually.
2015-05-19 13:28:46 +02:00
Birunthan Mohanathas 735ccdd101 Bug 968520 - Add mozilla::fallible to Fallible{Auto,}TArray::SetLength calls. r=froydnj 2015-05-18 13:50:35 -07:00
Birunthan Mohanathas 1f8d7454e3 Bug 968520 - Add mozilla::fallible to Fallible{Auto,}TArray::SetCapacity calls. r=froydnj 2015-05-18 13:50:34 -07:00