Changeset 1ff9922 in rtems


Ignore:
Timestamp:
Dec 22, 2007, 8:27:18 AM (12 years ago)
Author:
Chris Johns <chrisj@…>
Branches:
4.10, 4.11, 4.9, master
Children:
e85eb70
Parents:
e709ff4a
Message:

2007-12-22 Chris Johns <chrisj@…>

  • configure.ac: fixed bug that always enabled strict order mutexes.
  • score/inline/rtems/score/coremutex.inl: Fixed coding standard.
  • score/src/coremutex.c: Add the holder's thread to the lock_mutex list if the mutex is initialised locked.
  • libnetworking/rtems/rtems_glue.c: Changed semaphore error message to show the error is an rtems-net error.
  • libmisc/monitor/mon-network.c: Removed warnings.
  • telnetd/icmds.c: Changed shell_* to rtems_shell_*.
  • score/Makefile.am: Fixed typo that stopped 'make tags' working.
  • libmisc/shell/err.c, libmisc/shell/err.h, libmisc/shell/errx.c, libmisc/shell/extern-cp.h, libmisc/shell/fts.c, libmisc/shell/fts.h, libmisc/shell/main_cp.c, libmisc/shell/utils-cp.c, libmisc/shell/verr.c, libmisc/shell/verrx.c, libmisc/shell/vwarn.c, libmisc/shell/vwarnx.c, libmisc/shell/warn.c, libmisc/shell/warnx.c: New. Ported from BSD.
  • libmisc/shell/shellconfig.h: Add the cp command.
  • libmisc/Makefile.am: Add the new files to the shell.
  • libmisc/shell/shell.c, libmisc/shell/shell.h: Add scripting support.
  • libblock/src/flashdisk.c: Fixed disk drive count size setting bug.
Location:
cpukit
Files:
14 added
14 edited

Legend:

Unmodified
Added
Removed
  • cpukit/ChangeLog

    re709ff4a r1ff9922  
     12007-12-22      Chris Johns <chrisj@rtems.org>
     2
     3        * configure.ac: fixed bug that always enabled strict order
     4        mutexes.
     5        * score/inline/rtems/score/coremutex.inl: Fixed coding standard.
     6        * score/src/coremutex.c: Add the holder's thread to the lock_mutex
     7        list if the mutex is initialised locked.
     8        * libnetworking/rtems/rtems_glue.c: Changed semaphore error
     9        message to show the error is an rtems-net error.
     10        * libmisc/monitor/mon-network.c: Removed warnings.
     11        * telnetd/icmds.c: Changed shell_* to rtems_shell_*.
     12        * score/Makefile.am: Fixed typo that stopped 'make tags' working.
     13        * libmisc/shell/err.c, libmisc/shell/err.h, libmisc/shell/errx.c,
     14        libmisc/shell/extern-cp.h, libmisc/shell/fts.c,
     15        libmisc/shell/fts.h, libmisc/shell/main_cp.c,
     16        libmisc/shell/utils-cp.c, libmisc/shell/verr.c,
     17        libmisc/shell/verrx.c, libmisc/shell/vwarn.c,
     18        libmisc/shell/vwarnx.c, libmisc/shell/warn.c,
     19        libmisc/shell/warnx.c: New. Ported from BSD.
     20        * libmisc/shell/shellconfig.h: Add the cp command.
     21        * libmisc/Makefile.am: Add the new files to the shell.
     22        * libmisc/shell/shell.c, libmisc/shell/shell.h: Add scripting
     23        support.
     24        * libblock/src/flashdisk.c: Fixed disk drive count size setting
     25        bug.
     26       
    1272007-12-21      Xi Yang <hiyangxi@gmail.com>
    228
  • cpukit/configure.ac

    re709ff4a r1ff9922  
    235235## This gives the same behavior as 4.8 and older
    236236RTEMS_CPUOPT([__STRICT_ORDER_MUTEX__],
    237   [test x"${ENABLE_STRICT_ORDER_MUTEX}"=x"1"],
     237  [test x"${ENABLE_STRICT_ORDER_MUTEX}"= x"1"],
    238238  [1],
    239239  [disable strict order mutex]
  • cpukit/libblock/src/flashdisk.c

    re709ff4a r1ff9922  
    20032003/**
    20042004 * Flash disk WRITE request handler. This primitive copies data from
    2005  * supplied buffer to RAM disk and invoke the callout function to inform
     2005 * supplied buffer to flash disk and invoke the callout function to inform
    20062006 * upper layer that writing is completed.
    20072007 *
     
    23412341 * Flash disk device driver initialization.
    23422342 *
     2343 * @todo Memory clean up on error is really badly handled.
     2344 *
    23432345 * @param major Flash disk major device number.
    23442346 * @param minor Minor device number, not applicable.
     
    24202422      return RTEMS_NO_MEMORY;
    24212423
    2422     fd->block_count  = blocks;
     2424    fd->block_count = blocks;
    24232425
    24242426    fd->devices = calloc (c->device_count, sizeof (rtems_fdisk_device_ctl));
     
    24722474      rtems_fdisk_error ("compacting of disk failed: %s (%d)",
    24732475                         strerror (ret), ret);
    2474 
    2475     rtems_flashdisk_count = rtems_flashdisk_configuration_size;
    2476   }
     2476  }
     2477
     2478  rtems_flashdisk_count = rtems_flashdisk_configuration_size;
    24772479
    24782480  return RTEMS_SUCCESSFUL;
  • cpukit/libmisc/Makefile.am

    re709ff4a r1ff9922  
    6969    shell/main_mount_tftp.c
    7070endif
     71libshell_a_CPPFLAGS = $(AM_CPPFLAGS) -I$(srcdir)/shell
    7172libshell_a_SOURCES = shell/cat_file.c shell/cmds.c shell/internal.h \
    7273    shell/main_alias.c shell/main_cat.c shell/main_cd.c \
    7374    shell/main_chdir.c shell/main_chmod.c shell/main_chroot.c \
    74     shell/main_cpuuse.c shell/main_date.c shell/main_dir.c \
     75    shell/main_cp.c shell/main_cpuuse.c shell/main_date.c shell/main_dir.c \
    7576    shell/main_exit.c shell/main_help.c shell/main_id.c \
    7677    shell/main_logoff.c shell/main_ls.c shell/main_mallocinfo.c \
     
    8384    shell/main_blksync.c shell/main_whoami.c shell/shell.c \
    8485    shell/shell_cmdset.c shell/shellconfig.c shell/shellconfig.h \
    85     shell/shell.h shell/shell_makeargs.c shell/str2int.c shell/write_file.c
     86    shell/shell.h shell/shell_makeargs.c shell/str2int.c shell/write_file.c \
     87    shell/utils-cp.c shell/err.c shell/errx.c shell/verr.c shell/verrx.c \
     88    shell/vwarn.c shell/vwarnx.c shell/warn.c shell/warnx.c \
     89    shell/fts.c
    8690endif
    8791
  • cpukit/libmisc/monitor/mon-network.c

    re709ff4a r1ff9922  
    327327    }
    328328
    329     rc = rtems_bsdnet_rtrequest(cmd, &dst, &gw, &netmask, flags, NULL);
     329    rc = rtems_bsdnet_rtrequest(cmd,
     330                                (struct sockaddr*) &dst,
     331                                (struct sockaddr*) &gw,
     332                                (struct sockaddr*) &netmask, flags, NULL);
    330333    if (rc < 0) {
    331334        printf("Error adding route\n");
  • cpukit/libmisc/shell/main_mount_nfs.c

    re709ff4a r1ff9922  
    4444  }
    4545
     46  if (rpcUdpInit () < 0)
     47  {
     48    fprintf (stdout, "error: initialising RPC\n");
     49    return -1;
     50  }
     51
     52  nfsInit (0, 0);
     53 
    4654  uidhost = strdup (device);
    4755  path = strchr (uidhost, ':');
     
    5765
    5866rtems_shell_filesystems_t rtems_shell_Mount_NFS = {
    59   name:          "ftp",
     67  name:          "nfs",
    6068  driver_needed: 1,
    6169  fs_ops:        NULL,
  • cpukit/libmisc/shell/shell.c

    re709ff4a r1ff9922  
    5252  rtems_shell_env_t *shell_env;
    5353 
     54  if (rtems_global_shell_env.magic != 0x600D600d) {
     55    rtems_global_shell_env.magic         = 0x600D600d;
     56    rtems_global_shell_env.devname       = "";
     57    rtems_global_shell_env.taskname      = "GLOBAL";
     58    rtems_global_shell_env.tcflag        = 0;
     59    rtems_global_shell_env.exit_shell    = 0;
     60    rtems_global_shell_env.forever       = TRUE;
     61    rtems_global_shell_env.input         = 0;
     62    rtems_global_shell_env.output        = 0;
     63    rtems_global_shell_env.output_append = 0;
     64  }
     65
    5466  shell_env = shell_env_arg;
    5567
     
    5870    if ( !shell_env )
    5971     return NULL;
    60   }
    61 
    62   if (rtems_global_shell_env.magic != 0x600D600d) {
    63     rtems_global_shell_env.magic      = 0x600D600d;
    64     rtems_global_shell_env.devname    = "";
    65     rtems_global_shell_env.taskname   = "GLOBAL";
    66     rtems_global_shell_env.tcflag     = 0;
    67     rtems_global_shell_env.exit_shell = 0;
    68     rtems_global_shell_env.forever    = TRUE;
    69   }
    70 
    71   *shell_env = rtems_global_shell_env;
    72   shell_env->taskname = NULL;
    73   shell_env->forever = FALSE;
     72    *shell_env = rtems_global_shell_env;
     73    shell_env->taskname = NULL;
     74  }
    7475
    7576  return shell_env;
     
    345346rtems_task rtems_shell_task(rtems_task_argument task_argument)
    346347{
    347   rtems_shell_env_t * shell_env = (rtems_shell_env_t*) task_argument;
    348 
    349    rtems_shell_main_loop( shell_env );
    350    rtems_task_delete( RTEMS_SELF );
     348  rtems_shell_env_t *shell_env = (rtems_shell_env_t*) task_argument;
     349  rtems_id           wake_on_end = shell_env->wake_on_end;
     350  rtems_shell_main_loop( shell_env );
     351  if (wake_on_end != RTEMS_INVALID_ID)
     352    rtems_event_send (wake_on_end, RTEMS_EVENT_1);
     353  rtems_task_delete( RTEMS_SELF );
    351354}
    352355
     
    366369  int                argc;
    367370  char              *argv[RTEMS_SHELL_MAXIMUM_ARGUMENTS];
     371  rtems_boolean      result = TRUE;
     372  rtems_boolean      input_file = FALSE;
     373  int                line = 0;
    368374
    369375  rtems_shell_initialize_command_set();
    370376
     377  shell_env               =
     378  rtems_current_shell_env = rtems_shell_init_env( shell_env_arg );
     379 
    371380  /*
    372381   * @todo chrisj
    373    * Remove the use of task variables. Chnage to have a single
     382   * Remove the use of task variables. Change to have a single
    374383   * allocation per shell and then set into a notepad register
    375    * in the TCP. Provide a function to return the pointer.
     384   * in the TCB. Provide a function to return the pointer.
    376385   * Task variables are a virus to embedded systems software.
    377386   */
     
    382391  }
    383392
    384   shell_env               =
    385   rtems_current_shell_env = rtems_shell_init_env( shell_env_arg );
    386  
    387393  setuid(0);
    388394  setgid(0);
     
    390396  rtems_current_user_env->egid = 0;
    391397
     398  fileno(stdout);
     399
     400  if (strcmp(shell_env->output, "stdout") != 0) {
     401    if (strcmp(shell_env->output, "stderr") == 0) {
     402      stdout = stderr;
     403    } else if (strcmp(shell_env->output, "/dev/null") == 0) {
     404      fclose (stdout);
     405    } else {
     406      FILE *output = fopen(shell_env_arg->output,
     407                           shell_env_arg->output_append ? "a" : "w");
     408      if (!output) {
     409        fprintf(stderr, "shell: open output %s failed: %s\n",
     410                shell_env_arg->output, strerror(errno));
     411        return FALSE;
     412      }
     413      stdout = output;
     414    }
     415  }
     416 
     417  if (strcmp(shell_env_arg->input, "stdin") != 0) {
     418    FILE *input = fopen(shell_env_arg->input, "r");
     419    if (!input) {
     420      fprintf(stderr, "shell: open input %s failed: %s\n",
     421              shell_env_arg->input, strerror(errno));
     422      return FALSE;
     423    }
     424    stdin = input;
     425    shell_env->forever = FALSE;
     426    input_file = TRUE;
     427  }
     428  else {
     429    /* make a raw terminal,Linux Manuals */
     430    if (tcgetattr(fileno(stdin), &term) >= 0) {
     431      term.c_iflag &= ~(IGNBRK|BRKINT|PARMRK|ISTRIP|INLCR|IGNCR|ICRNL|IXON);
     432      term.c_oflag &= ~OPOST;
     433      term.c_oflag |= (OPOST|ONLCR); /* But with cr+nl on output */
     434      term.c_lflag &= ~(ECHO|ECHONL|ICANON|ISIG|IEXTEN);
     435      if (shell_env->tcflag)
     436        term.c_cflag = shell_env->tcflag;
     437      term.c_cflag  |= CLOCAL | CREAD;
     438      term.c_cc[VMIN]  = 1;
     439      term.c_cc[VTIME] = 0;
     440      if (tcsetattr (fileno(stdin), TCSADRAIN, &term) < 0) {
     441        fprintf(stderr,
     442                "shell:cannot set terminal attributes(%s)\n",shell_env->devname);
     443      }
     444    }
     445  }
     446
    392447  setvbuf(stdin,NULL,_IONBF,0); /* Not buffered*/
    393   /* make a raw terminal,Linux Manuals */
    394   if (tcgetattr(fileno(stdin), &term) >= 0) {
    395     term.c_iflag &= ~(IGNBRK|BRKINT|PARMRK|ISTRIP|INLCR|IGNCR|ICRNL|IXON);
    396     term.c_oflag &= ~OPOST;
    397     term.c_oflag |= (OPOST|ONLCR); /* But with cr+nl on output */
    398     term.c_lflag &= ~(ECHO|ECHONL|ICANON|ISIG|IEXTEN);
    399     if (shell_env->tcflag)
    400       term.c_cflag = shell_env->tcflag;
    401     term.c_cflag  |= CLOCAL | CREAD;
    402     term.c_cc[VMIN]  = 1;
    403     term.c_cc[VTIME] = 0;
    404     if (tcsetattr (fileno(stdin), TCSADRAIN, &term) < 0) {
    405       fprintf(stderr,
    406         "shell:cannot set terminal attributes(%s)\n",shell_env->devname);
    407     }
    408     setvbuf(stdout,NULL,_IONBF,0); /* Not buffered*/
    409   }
     448  setvbuf(stdout,NULL,_IONBF,0); /* Not buffered*/
    410449
    411450  rtems_shell_initialize_command_set();
     
    415454    if (sc != RTEMS_SUCCESSFUL) {
    416455      rtems_error(sc,"rtems_libio_set_private_env():");
    417       return FALSE;
     456      result = FALSE;
     457      break;
    418458    }
    419     if (!rtems_shell_login(stdin,stdout))  {
    420       rtems_shell_cat_file(stdout,"/etc/motd");
     459    if (input_file || !rtems_shell_login(stdin,stdout))  {
     460      const char *c;
    421461      strcpy(last_cmd,"");
    422462      strcpy(cmd,"");
    423       printf("\n"
    424         "RTEMS SHELL (Ver.1.0-FRC):%s. "__DATE__". 'help' to list commands.\n",
    425         shell_env->devname);
     463      if (!input_file) {
     464        rtems_shell_cat_file(stdout,"/etc/motd");
     465        fprintf(stdout, "\n"
     466                "RTEMS SHELL (Ver.1.0-FRC):%s. " \
     467                __DATE__". 'help' to list commands.\n",
     468                shell_env->devname);
     469      }
    426470      chdir("/"); /* XXX: chdir to getpwent homedir */
    427471      shell_env->exit_shell = FALSE;
    428472      for (;;) {
    429473        /* Prompt section */
    430         /* XXX: show_prompt user adjustable */
    431         getcwd(curdir,sizeof(curdir));
    432         printf( "%s%s[%s] %c ",
    433           ((shell_env->taskname) ? shell_env->taskname : ""),
    434           ((shell_env->taskname) ? " " : ""),
    435           curdir,
    436           geteuid()?'$':'#'
    437         );
     474        if (!input_file) {
     475          /* XXX: show_prompt user adjustable */
     476          getcwd(curdir,sizeof(curdir));
     477          fprintf(stdout, "%s%s[%s] %c ",
     478                  ((shell_env->taskname) ? shell_env->taskname : ""),
     479                  ((shell_env->taskname) ? " " : ""),
     480                  curdir,
     481                  geteuid()?'$':'#');
     482        }
     483       
    438484        /* getcmd section */
    439485        if (!rtems_shell_scanline(cmd,sizeof(cmd),stdin,stdout)) {
     
    441487        }
    442488
     489        line++;
     490
    443491        /* evaluate cmd section */
     492        c = cmd;
     493        while (*c) {
     494          if (!isblank(*c))
     495            break;
     496          c++;
     497        }
     498
     499        if (*c == '\0')                 /* empty line */
     500          continue;
     501        if (*c == '#')                  /* comment character */
     502          continue;
     503
    444504        if (!strcmp(cmd,"e")) {         /* edit last command */
    445505          strcpy(cmd,last_cmd);
     
    447507        } else if (!strcmp(cmd,"r")) {  /* repeat last command */
    448508          strcpy(cmd,last_cmd);
    449         } else if (!strcmp(cmd,"bye")) { /* exit to telnetd */
    450           printf("Shell exiting\n" );
    451           return TRUE;
    452         } else if (!strcmp(cmd,"exit")) { /* exit application */
    453           printf("System shutting down at user request\n" );
     509        } else if (!strcmp(cmd,"bye") || !strcmp(cmd,"exit")) {
     510          fprintf(stdout, "Shell exiting\n" );
     511          break;
     512        } else if (!strcmp(cmd,"shutdown")) { /* exit application */
     513          fprintf(stdout, "System shutting down at user request\n" );
    454514          exit(0);
    455515        } else if (!strcmp(cmd,"")) {    /* only for get a new prompt */
     
    470530            shell_env->errorlevel = -1;
    471531          } else if ( shell_cmd == NULL ) {
    472             printf("shell:%s command not found\n", argv[0]);
     532            fprintf(stdout, "shell:%s command not found\n", argv[0]);
    473533            shell_env->errorlevel = -1;
    474534          } else {
     
    483543        cmd[0] = 0;
    484544      }
    485       printf("\nGoodbye from RTEMS SHELL :-(\n");
    486545      fflush( stdout );
    487546      fflush( stderr );
    488547    }
    489   } while (shell_env->forever);
    490   return TRUE;
     548  } while (result && shell_env->forever);
     549  return result;
    491550}
    492551
    493552/* ----------------------------------------------- */
    494 rtems_status_code   rtems_shell_init (
     553static rtems_status_code   rtems_shell_run (
    495554  char                *task_name,
    496555  uint32_t             task_stacksize,
     
    498557  char                *devname,
    499558  tcflag_t             tcflag,
    500   int                  forever
     559  int                  forever,
     560  const char*          input,
     561  const char*          output,
     562  int                  output_append,
     563  rtems_id             wake_on_end
    501564)
    502565{
     
    527590  shell_env = rtems_shell_init_env( NULL );
    528591  if ( !shell_env )  {
    529    rtems_error(sc,"allocating shell_env %s in shell_init()",task_name);
     592   rtems_error(RTEMS_NO_MEMORY,
     593               "allocating shell_env %s in shell_init()",task_name);
    530594   return RTEMS_NO_MEMORY;
    531595  }
    532   shell_env->devname    = devname;
    533   shell_env->taskname   = task_name;
    534   shell_env->tcflag     = tcflag;
    535   shell_env->exit_shell = FALSE;
    536   shell_env->forever    = forever;
     596  shell_env->devname       = devname;
     597  shell_env->taskname      = task_name;
     598  shell_env->tcflag        = tcflag;
     599  shell_env->exit_shell    = FALSE;
     600  shell_env->forever       = forever;
     601  shell_env->input         = strdup (input);
     602  shell_env->output        = strdup (output);
     603  shell_env->output_append = output_append;
     604  shell_env->wake_on_end   = wake_on_end;
    537605
    538606  return rtems_task_start(task_id, rtems_shell_task,
    539607                          (rtems_task_argument) shell_env);
    540608}
     609
     610rtems_status_code   rtems_shell_init (
     611  char                *task_name,
     612  uint32_t             task_stacksize,
     613  rtems_task_priority  task_priority,
     614  char                *devname,
     615  tcflag_t             tcflag,
     616  int                  forever
     617)
     618{
     619  return rtems_shell_run (task_name, task_stacksize, task_priority,
     620                          devname, tcflag, forever,
     621                          "stdin", "stdout", 0, RTEMS_INVALID_ID);
     622}
     623
     624rtems_status_code   rtems_shell_script (
     625  char                *task_name,
     626  uint32_t             task_stacksize,
     627  rtems_task_priority  task_priority,
     628  const char*          input,
     629  const char*          output,
     630  int                  output_append,
     631  int                  wait
     632)
     633{
     634  rtems_id          current_task = RTEMS_INVALID_ID;
     635  rtems_status_code sc;
     636
     637  if (wait) {
     638    sc = rtems_task_ident (RTEMS_SELF, RTEMS_LOCAL, &current_task);
     639    if (sc != RTEMS_SUCCESSFUL)
     640      return sc;
     641  }
     642 
     643  sc = rtems_shell_run (task_name, task_stacksize, task_priority,
     644                        NULL, 0, 0, input, output, output_append,
     645                        current_task);
     646  if (sc != RTEMS_SUCCESSFUL)
     647    return sc;
     648
     649  if (wait) {
     650    rtems_event_set out;
     651    sc = rtems_event_receive (RTEMS_EVENT_1, RTEMS_WAIT, 0, &out);
     652  }
     653
     654  return sc;
     655}
  • cpukit/libmisc/shell/shell.h

    re709ff4a r1ff9922  
    102102);
    103103
     104/**
     105 * Run a shell script creating a shell tasks to execute the command under.
     106 *
     107 * @param task_name Name of the shell task.
     108 * @param task_stacksize The size of the stack. If 0 the default size is used.
     109 * @param task_priority The priority the shell runs at.
     110 * @param input The file of commands. Can be 'stdin' to use stdin.
     111 * @param output The output file to write commands to. Can be 'stdout',
     112 *              'stderr' or '/dev/null'.
     113 * @param output_append Append the output to the file or truncate the file.
     114 *                      Create if it does not exist.
     115 * @param wait Wait for the script to finish.
     116 */
     117rtems_status_code rtems_shell_script(
     118  char                *task_name,
     119  uint32_t             task_stacksize,  /*0 default*/
     120  rtems_task_priority  task_priority,
     121  const char          *input,
     122  const char          *output,
     123  int                  output_append,
     124  int                  wait
     125);
     126
    104127/*
    105128 *  Things that are useful to external entities developing commands and plugging
     
    118141  int         errorlevel;
    119142  uintptr_t   mdump_addr;
     143  const char* input;
     144  const char* output;
     145  int         output_append;
     146  rtems_id    wake_on_end;
    120147} rtems_shell_env_t;
    121148
  • cpukit/libmisc/shell/shellconfig.h

    re709ff4a r1ff9922  
    3535extern rtems_shell_cmd_t rtems_shell_WHOAMI_Command;
    3636
     37extern rtems_shell_cmd_t rtems_shell_CP_Command;
    3738extern rtems_shell_cmd_t rtems_shell_PWD_Command;
    3839extern rtems_shell_cmd_t rtems_shell_LS_Command;
     
    193194     *  File and directory commands
    194195     */
     196    #if (defined(CONFIGURE_SHELL_COMMANDS_ALL) && \
     197         !defined(CONFIGURE_SHELL_NO_COMMAND_CP)) || \
     198        defined(CONFIGURE_SHELL_COMMAND_CP)
     199      &rtems_shell_CP_Command,
     200    #endif
    195201    #if (defined(CONFIGURE_SHELL_COMMANDS_ALL) && \
    196202         !defined(CONFIGURE_SHELL_NO_COMMAND_PWD)) || \
  • cpukit/libnetworking/rtems/rtems_glue.c

    re709ff4a r1ff9922  
    312312                );
    313313        if (_Thread_Executing->Wait.return_code)
    314                 rtems_panic ("Can't obtain network semaphore\n");
     314                rtems_panic ("rtems-net: can't obtain network sema: %d\n",
     315                 _Thread_Executing->Wait.return_code);
    315316#else
    316317        rtems_status_code sc;
     
    318319        sc = rtems_semaphore_obtain (networkSemaphore, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
    319320        if (sc != RTEMS_SUCCESSFUL)
    320                 rtems_panic ("Can't obtain network semaphore: `%s'\n", rtems_status_text (sc));
     321                rtems_panic ("rtems-net: can't obtain network semaphore: `%s'\n",
     322                 rtems_status_text (sc));
    321323#endif
    322324}
     
    339341        _Thread_Enable_dispatch();
    340342        if (i)
    341                 rtems_panic ("Can't release network semaphore\n");
     343                rtems_panic ("rtems-net: can't release network sema: %i\n");
    342344#else
    343345        rtems_status_code sc;
     
    345347        sc = rtems_semaphore_release (networkSemaphore);
    346348        if (sc != RTEMS_SUCCESSFUL)
    347                 rtems_panic ("Can't release network semaphore: `%s'\n", rtems_status_text (sc));
     349                rtems_panic ("rtems-net: can't release network semaphore: `%s'\n",
     350                 rtems_status_text (sc));
    348351#endif
    349352}
  • cpukit/score/Makefile.am

    re709ff4a r1ff9922  
    114114    src/objectclearname.c src/objectcomparenameraw.c \
    115115    src/objectcomparenamestring.c src/objectcopynameraw.c \
    116     src/objectcopynamestring.c \ src/objectextendinformation.c \
     116    src/objectcopynamestring.c src/objectextendinformation.c \
    117117    src/objectfree.c src/objectget.c src/objectgetisr.c src/objectgetnext.c \
    118118    src/objectinitializeinformation.c src/objectnametoid.c \
  • cpukit/score/inline/rtems/score/coremutex.inl

    re709ff4a r1ff9922  
    142142
    143143#ifdef __STRICT_ORDER_MUTEX__
    144        _Chain_Prepend_unprotected(&executing->lock_mutex,&the_mutex->queue.lock_queue);
     144       _Chain_Prepend_unprotected( &executing->lock_mutex,
     145                                   &the_mutex->queue.lock_queue );
    145146       the_mutex->queue.priority_before = executing->current_priority;
    146147#endif
  • cpukit/score/src/coremutex.c

    re709ff4a r1ff9922  
    6565    if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) ||
    6666         _CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) )
     67     
     68#ifdef __STRICT_ORDER_MUTEX__
     69       _Chain_Prepend_unprotected( &executing->lock_mutex,
     70                                   &the_mutex->queue.lock_queue );
     71       the_mutex->queue.priority_before = executing->current_priority;
     72#endif
     73
    6774      _Thread_Executing->resource_count++;
    6875  } else {
  • cpukit/telnetd/icmds.c

    re709ff4a r1ff9922  
    5555
    5656void _rtems_telnetd_register_icmds(void) {
    57  shell_add_cmd("inet"    ,"net","inet routes"               ,main_inet);   
    58  shell_add_cmd("mbuf"    ,"net","mbuf stats"                ,main_mbuf);   
    59  shell_add_cmd("if"      ,"net","if   stats"                ,main_if  );   
    60  shell_add_cmd("ip"      ,"net","ip   stats"                ,main_ip  );   
    61  shell_add_cmd("icmp"    ,"net","icmp stats"                ,main_icmp);   
    62  shell_add_cmd("tcp"     ,"net","tcp  stats"                ,main_tcp );   
    63  shell_add_cmd("udp"     ,"net","udp  stats"                ,main_udp );   
     57 rtems_shell_add_cmd("inet"    ,"net","inet routes"               ,main_inet);   
     58 rtems_shell_add_cmd("mbuf"    ,"net","mbuf stats"                ,main_mbuf);   
     59 rtems_shell_add_cmd("if"      ,"net","if   stats"                ,main_if  );   
     60 rtems_shell_add_cmd("ip"      ,"net","ip   stats"                ,main_ip  );   
     61 rtems_shell_add_cmd("icmp"    ,"net","icmp stats"                ,main_icmp);   
     62 rtems_shell_add_cmd("tcp"     ,"net","tcp  stats"                ,main_tcp );   
     63 rtems_shell_add_cmd("udp"     ,"net","udp  stats"                ,main_udp );   
    6464}
Note: See TracChangeset for help on using the changeset viewer.