mirror of
https://git.rtems.org/rtems-libbsd/
synced 2025-10-14 18:05:28 +08:00
Add smp variables used by e1000 and remove unneeded ifdefs
+ added machine/smp.h as empty file + added rtems-bsd-smp.c for a few variables which were needed
This commit is contained in:
40
rtemsbsd/src/rtems-bsd-smp.c
Normal file
40
rtemsbsd/src/rtems-bsd-smp.c
Normal file
@@ -0,0 +1,40 @@
|
||||
/**
|
||||
* @file
|
||||
*
|
||||
* @ingroup rtems_bsd_rtems
|
||||
*
|
||||
* @brief TODO.
|
||||
*/
|
||||
|
||||
/*
|
||||
* COPYRIGHT (c) 1989-2012.
|
||||
* On-Line Applications Research Corporation (OAR).
|
||||
*
|
||||
* The license and distribution terms for this file may be
|
||||
* found in the file LICENSE in this distribution or at
|
||||
* http://www.rtems.com/license/LICENSE.
|
||||
*
|
||||
*/
|
||||
|
||||
#include <freebsd/machine/rtems-bsd-config.h>
|
||||
|
||||
#include <freebsd/sys/types.h>
|
||||
|
||||
#include <freebsd/sys/smp.h>
|
||||
#include <freebsd/machine/smp.h>
|
||||
|
||||
int mp_ncpus;
|
||||
int mp_maxcpus;
|
||||
|
||||
static void configure(void *dummy)
|
||||
{
|
||||
#if defined(RTEMS_SMP)
|
||||
mp_ncpus = rtems_smp_get_number_of_processors();
|
||||
mp_maxcpus = rtems_configuration_smp_maximum_processors;
|
||||
#else
|
||||
mp_ncpus = 1;
|
||||
mp_maxcpus = 1;
|
||||
#endif
|
||||
}
|
||||
|
||||
/* XXX setup initialization of this */
|
Reference in New Issue
Block a user