Changeset 856b75b7 in mainline for uspace/srv/sysman/main.c


Ignore:
Timestamp:
2020-01-09T01:04:56Z (4 years ago)
Author:
Matthieu Riolo <matthieu.riolo@…>
Children:
5d35021
Parents:
e7faeba
git-author:
Matthieu Riolo <matthieu.riolo@…> (2019-12-14 19:27:08)
git-committer:
Matthieu Riolo <matthieu.riolo@…> (2020-01-09 01:04:56)
Message:

Correcting port handler in sysman

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/sysman/main.c

    re7faeba r856b75b7  
    6868static void sysman_connection(ipc_call_t *icall, void *arg)
    6969{
    70         sysman_interface_t iface = ipc_get_arg1(icall);
    71         switch (iface) {
    72         case SYSMAN_PORT_BROKER:
    73                 sysman_connection_broker(icall);
    74                 break;
    75         case SYSMAN_PORT_CTL:
    76                 sysman_connection_ctl(icall);
    77                 break;
    78         default:
    79                 /* Unknown interface */
    80                 async_answer_0(icall, ENOENT);
     70        async_accept_0(icall);
     71
     72        while (true) {
     73                ipc_call_t call;
     74                async_get_call(&call);
     75
     76                if (!ipc_get_imethod(&call)) {
     77                        async_answer_0(&call, EOK);
     78                        break;
     79                }
     80
     81                sysman_interface_t iface = ipc_get_arg1(&call);
     82                switch (iface) {
     83                case SYSMAN_PORT_BROKER:
     84                        sysman_connection_broker(&call);
     85                        break;
     86                case SYSMAN_PORT_CTL:
     87                        sysman_connection_ctl(&call);
     88                        break;
     89                default:
     90                        /* Unknown interface */
     91                        async_answer_0(&call, ENOENT);
     92                }
    8193        }
    8294}
Note: See TracChangeset for help on using the changeset viewer.