From a7db1f6930505ab6a70b0cb41a4c2d52a9448a08 Mon Sep 17 00:00:00 2001 From: olgeni Date: Wed, 7 Aug 2013 12:48:09 +0200 Subject: Misc. corrections for erl_driver(3) - Remove trailing whitespaces - Spelling fixes - Replace "deferred" with "deprecated" where applicable - Remove reference to non-existing "async_ready" entry point --- erts/doc/src/erl_driver.xml | 37 ++++++++++++++++++------------------- 1 file changed, 18 insertions(+), 19 deletions(-) diff --git a/erts/doc/src/erl_driver.xml b/erts/doc/src/erl_driver.xml index efe0483b31..f52d973709 100644 --- a/erts/doc/src/erl_driver.xml +++ b/erts/doc/src/erl_driver.xml @@ -666,7 +666,7 @@ typedef struct ErlDrvBinary {

The ErlDrvData is a handle to driver-specific data, passed to the driver call-backs. It is a pointer, and is - most often type casted to a specific pointer in the driver.

+ most often type cast to a specific pointer in the driver.

SysIOVec @@ -1014,7 +1014,7 @@ typedef struct ErlIOVec { Read a system timestamp -

This function reads a timestamp into the memory pointed to by +

This function reads a timestamp into the memory pointed to by the parameter now. See the description of ErlDrvNowData for specification of its fields.

The return value is 0 unless the now pointer is not @@ -1056,7 +1056,7 @@ typedef struct ErlIOVec { returned. Another thread may still be using the event object internally. To safely close an event object call driver_select with ERL_DRV_USE and on==0. That - will clear all events and then call + will clear all events and then call stop_select when it is safe to close the event object. ERL_DRV_USE should be set together with the first event @@ -1068,7 +1068,7 @@ typedef struct ErlIOVec {

ERL_DRV_USE was added in OTP release R13. Old drivers will still work as before. But it is recommended to update them to use ERL_DRV_USE and stop_select to make sure that event objects are closed in a safe way.

- +

The return value is 0 (failure, -1, only if the ready_input/ready_output is NULL).

@@ -1524,7 +1524,7 @@ typedef struct ErlIOVec {

This function removes a driver entry de previously added with add_driver_entry.

-

Driver entries added by the erl_ddll erlang interface can +

Driver entries added by the erl_ddll erlang interface can not be removed by using this interface.

@@ -1758,7 +1758,7 @@ typedef struct ErlIOVec {
 Term type            Argument(s)
 ===========================================
-ERL_DRV_NIL          
+ERL_DRV_NIL
 ERL_DRV_ATOM         ErlDrvTermData atom (from driver_mk_atom(char *string))
 ERL_DRV_INT          ErlDrvSInt integer
 ERL_DRV_UINT         ErlDrvUInt integer
@@ -1779,11 +1779,11 @@ ERL_DRV_EXT2TERM     char *buf, ErlDrvUInt len
 	  signed integer data type ErlDrvSInt are 64 bits wide
 	  on a 64 bit runtime system and 32 bits wide on a 32 bit
 	  runtime system. They were introduced in erts version 5.6,
-	  and replaced some of the int arguments in the list above. 
+	  and replaced some of the int arguments in the list above.
 	

The unsigned integer data type ErlDrvUInt64 and the signed integer data type ErlDrvSInt64 are always 64 bits - wide. They were introduced in erts version 5.7.4. + wide. They were introduced in erts version 5.7.4.

To build the tuple {tcp, Port, [100 | Binary]}, the @@ -1879,7 +1879,7 @@ ERL_DRV_EXT2TERM char *buf, ErlDrvUInt len Send term data from driver to port owner -

driver_output_term() is deferred and will +

driver_output_term() is deprecated and will be removed in the OTP-R17 release. Use erl_drv_output_term() instead.

@@ -1937,7 +1937,7 @@ ERL_DRV_EXT2TERM char *buf, ErlDrvUInt len Send term data to other process than port owner process -

driver_send_term() is deferred and will +

driver_send_term() is deprecated and will be removed in the OTP-R17 release. Use erl_drv_send_term() instead.

@@ -1998,7 +1998,7 @@ ERL_DRV_EXT2TERM char *buf, ErlDrvUInt len The data should be freed in async_free, because it's called if driver_async_cancel is called.

When the async operation is done, ready_async driver - entry function is called. If async_ready is null in + entry function is called. If ready_async is null in the driver entry, the async_free function is called instead.

The return value is a handle to the asynchronous task, which @@ -2035,7 +2035,7 @@ ERL_DRV_EXT2TERM char *buf, ErlDrvUInt len as of OTP-R15B driver_async_cancel() is deprecated, and scheduled for removal in OTP-R16. It will currently always fail, and return 0.

-

driver_async_cancel() is deferred and will +

driver_async_cancel() is deprecated and will be removed in the OTP-R16 release.

@@ -2048,7 +2048,7 @@ ERL_DRV_EXT2TERM char *buf, ErlDrvUInt len

This function locks the driver used by the port port in memory for the rest of the emulator process' - lifetime. After this call, the driver behaves as one of Erlang's + lifetime. After this call, the driver behaves as one of Erlang's statically linked in drivers.

@@ -2076,7 +2076,7 @@ ERL_DRV_EXT2TERM char *buf, ErlDrvUInt len driver_entry). drv_data The driver defined handle that will be passed in subsequent - calls to driver call-backs. Note, that the + calls to driver call-backs. Note, that the driver start call-back will not be called for this new driver instance. The driver defined handle is normally created in the @@ -2284,7 +2284,7 @@ ERL_DRV_EXT2TERM char *buf, ErlDrvUInt len A thread identifier.

This function compares two thread identifiers for equality, - and returns 0 it they aren't equal, and + and returns 0 it they aren't equal, and a value not equal to 0 if they are equal.

A Thread identifier may be reused very quickly after a thread has terminated. Therefore, if a thread @@ -2469,7 +2469,7 @@ ERL_DRV_EXT2TERM char *buf, ErlDrvUInt len

This function broadcasts on a condition variable. That is, if other threads are waiting on the condition variable being - broadcasted on, all of them will be woken. + broadcast on, all of them will be woken.

This function is thread-safe.

@@ -2498,7 +2498,7 @@ ERL_DRV_EXT2TERM char *buf, ErlDrvUInt len the calling thread when calling this function.

erl_drv_cond_wait() might return even though - no-one has signaled or broadcasted on the condition + no-one has signaled or broadcast on the condition variable. Code calling erl_drv_cond_wait() should always be prepared for erl_drv_cond_wait() returning even though the condition that the thread was @@ -2822,7 +2822,7 @@ ERL_DRV_EXT2TERM char *buf, ErlDrvUInt len A pointer to an output buffer. value_size A pointer to an integer. The integer is both used for - passing input and output sizes (see below). + passing input and output sizes (see below).

This function retrieves the value of an environment variable. @@ -2900,4 +2900,3 @@ ERL_DRV_EXT2TERM char *buf, ErlDrvUInt len Guide Ch. 3)

- -- cgit v1.2.3