Changeset 83a2f43 in mainline for uspace/drv/ns8250


Ignore:
Timestamp:
2011-02-15T19:43:50Z (15 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
af6b5157
Parents:
34588a80
Message:

Rename bunch of stuff so that it starts with 'ddf_'.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/ns8250/ns8250.c

    r34588a80 r83a2f43  
    9494typedef struct ns8250 {
    9595        /** DDF device node */
    96         device_t *dev;
     96        ddf_dev_t *dev;
    9797        /** DDF function node */
    98         function_t *fun;
     98        ddf_fun_t *fun;
    9999        /** Is there any client conntected to the device? */
    100100        bool client_connected;
     
    189189 *                      error number otherwise.
    190190 */
    191 static int ns8250_read(function_t *fun, char *buf, size_t count)
     191static int ns8250_read(ddf_fun_t *fun, char *buf, size_t count)
    192192{
    193193        ns8250_t *ns = NS8250(fun);
     
    223223 * @return              Zero on success
    224224 */
    225 static int ns8250_write(function_t *fun, char *buf, size_t count)
     225static int ns8250_write(ddf_fun_t *fun, char *buf, size_t count)
    226226{
    227227        ns8250_t *ns = NS8250(fun);
     
    234234}
    235235
    236 static device_ops_t ns8250_dev_ops;
     236static ddf_dev_ops_t ns8250_dev_ops;
    237237
    238238/** The character interface's callbacks. */
     
    242242};
    243243
    244 static int ns8250_add_device(device_t *dev);
     244static int ns8250_add_device(ddf_dev_t *dev);
    245245
    246246/** The serial port device driver's standard operations. */
     
    675675 * @param dev           The serial port device.
    676676 */
    677 static inline void ns8250_interrupt_handler(device_t *dev, ipc_callid_t iid,
     677static inline void ns8250_interrupt_handler(ddf_dev_t *dev, ipc_callid_t iid,
    678678    ipc_call_t *icall)
    679679{
     
    706706 * @param dev           The serial port device.
    707707 */
    708 static int ns8250_add_device(device_t *dev)
     708static int ns8250_add_device(ddf_dev_t *dev)
    709709{
    710710        ns8250_t *ns = NULL;
    711         function_t *fun = NULL;
     711        ddf_fun_t *fun = NULL;
    712712        bool need_cleanup = false;
    713713        int rc;
     
    777777        ns->fun = fun;
    778778       
    779         add_function_to_class(fun, "serial");
     779        ddf_fun_add_to_class(fun, "serial");
    780780       
    781781        printf(NAME ": the %s device has been successfully initialized.\n",
     
    800800 * @param dev           The device.
    801801 */
    802 static int ns8250_open(function_t *fun)
     802static int ns8250_open(ddf_fun_t *fun)
    803803{
    804804        ns8250_t *data = (ns8250_t *) fun->dev->driver_data;
     
    824824 * @param dev           The device.
    825825 */
    826 static void ns8250_close(function_t *fun)
     826static void ns8250_close(ddf_fun_t *fun)
    827827{
    828828        ns8250_t *data = (ns8250_t *) fun->dev->driver_data;
     
    848848 */
    849849static void
    850 ns8250_get_props(device_t *dev, unsigned int *baud_rate, unsigned int *parity,
     850ns8250_get_props(ddf_dev_t *dev, unsigned int *baud_rate, unsigned int *parity,
    851851    unsigned int *word_length, unsigned int* stop_bits)
    852852{
     
    875875 * @param stop_bits     The number of stop bits to be used.
    876876 */
    877 static int ns8250_set_props(device_t *dev, unsigned int baud_rate,
     877static int ns8250_set_props(ddf_dev_t *dev, unsigned int baud_rate,
    878878    unsigned int parity, unsigned int word_length, unsigned int stop_bits)
    879879{
     
    902902 * Configure the parameters of the serial communication.
    903903 */
    904 static void ns8250_default_handler(function_t *fun, ipc_callid_t callid,
     904static void ns8250_default_handler(ddf_fun_t *fun, ipc_callid_t callid,
    905905    ipc_call_t *call)
    906906{
     
    950950        printf(NAME ": HelenOS serial port driver\n");
    951951        ns8250_init();
    952         return driver_main(&ns8250_driver);
     952        return ddf_driver_main(&ns8250_driver);
    953953}
    954954
Note: See TracChangeset for help on using the changeset viewer.