forked from Imagelibrary/rtems
tools: Remove shgen
All tools should be removed from the RTEMS source repository at some point in time. Tools with a BSD-style license will be moved to the RTEMS tools repository. Unfortunately, the shgen tool is GPL licensed. Remove all uses of this tool from the code base. Replace generated files with stub functions. If users of this BSP still exist, they can reimplement the functionality using a BSD-style license. Close #3443.
This commit is contained in:
@@ -18,7 +18,7 @@
|
||||
* http://www.rtems.org/license/LICENSE.
|
||||
*/
|
||||
|
||||
#include <rtems.h>
|
||||
#include <bsp.h>
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
@@ -53,12 +53,6 @@ struct scidev_t {
|
||||
{ "/dev/sci1", SH_SCI_BASE_1, 1, 0, CS8, B9600 }
|
||||
} ;
|
||||
|
||||
/* imported from scitab.rel */
|
||||
extern int _sci_get_brparms(
|
||||
speed_t spd,
|
||||
unsigned char *smr,
|
||||
unsigned char *brr );
|
||||
|
||||
/* Translate termios' tcflag_t into sci settings */
|
||||
static int _sci_set_cflags(
|
||||
struct scidev_t *sci_dev,
|
||||
|
||||
38
bsps/sh/gensh1/console/scitab.c
Normal file
38
bsps/sh/gensh1/console/scitab.c
Normal file
@@ -0,0 +1,38 @@
|
||||
/*
|
||||
* Copyright (c) 2018 embedded brains GmbH. All rights reserved.
|
||||
*
|
||||
* embedded brains GmbH
|
||||
* Dornierstr. 4
|
||||
* 82178 Puchheim
|
||||
* Germany
|
||||
* <info@embedded-brains.de>
|
||||
*
|
||||
* The license and distribution terms for this file may be
|
||||
* found in the file LICENSE in this distribution or at
|
||||
* http://www.rtems.org/license/LICENSE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The content of this file was previously generated by the GPL licensed shgen
|
||||
* tool during the BSP build for a configured clock frequency
|
||||
* (CPU_CLOCK_RATE_HZ). All tools were removed from the RTEMS source repository
|
||||
* at some point in time. Tools with a BSD-style license were moved to the
|
||||
* RTEMS tools repository.
|
||||
*/
|
||||
|
||||
#include <bsp.h>
|
||||
|
||||
int _sci_get_brparms(
|
||||
unsigned int spd,
|
||||
unsigned char *smr,
|
||||
unsigned char *brr
|
||||
)
|
||||
{
|
||||
if (spd != 9600) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
*smr = 0x00;
|
||||
*brr = 0x40;
|
||||
return 0;
|
||||
}
|
||||
@@ -60,8 +60,8 @@ extern void *CPU_Interrupt_stack_high;
|
||||
*/
|
||||
void bsp_hw_init(void);
|
||||
|
||||
extern int _sci_get_brparms(
|
||||
tcflag_t cflag,
|
||||
int _sci_get_brparms(
|
||||
unsigned int spd,
|
||||
unsigned char *smr,
|
||||
unsigned char *brr
|
||||
);
|
||||
|
||||
@@ -73,8 +73,7 @@
|
||||
#define SH_SCI_BASE_1 SCI_SMR1
|
||||
|
||||
#define SH_SCI_DEF_COMM_0 CS8, B9600
|
||||
#define SH_SCI_DEF_COMM_1 CS8, B38400
|
||||
/* #define SH_SCI_DEF_COMM_1 CS8, B9600 */
|
||||
#define SH_SCI_DEF_COMM_1 CS8, B9600
|
||||
|
||||
struct scidev_t {
|
||||
char * name;
|
||||
|
||||
38
bsps/sh/gensh2/console/scitab.c
Normal file
38
bsps/sh/gensh2/console/scitab.c
Normal file
@@ -0,0 +1,38 @@
|
||||
/*
|
||||
* Copyright (c) 2018 embedded brains GmbH. All rights reserved.
|
||||
*
|
||||
* embedded brains GmbH
|
||||
* Dornierstr. 4
|
||||
* 82178 Puchheim
|
||||
* Germany
|
||||
* <info@embedded-brains.de>
|
||||
*
|
||||
* The license and distribution terms for this file may be
|
||||
* found in the file LICENSE in this distribution or at
|
||||
* http://www.rtems.org/license/LICENSE.
|
||||
*/
|
||||
|
||||
/*
|
||||
* The content of this file was previously generated by the GPL licensed shgen
|
||||
* tool during the BSP build for a configured clock frequency
|
||||
* (CPU_CLOCK_RATE_HZ). All tools were removed from the RTEMS source repository
|
||||
* at some point in time. Tools with a BSD-style license were moved to the
|
||||
* RTEMS tools repository.
|
||||
*/
|
||||
|
||||
#include <bsp.h>
|
||||
|
||||
int _sci_get_brparms(
|
||||
unsigned int spd,
|
||||
unsigned char *smr,
|
||||
unsigned char *brr
|
||||
)
|
||||
{
|
||||
if (spd != 9600) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
*smr = 0x00;
|
||||
*brr = 0x5f;
|
||||
return 0;
|
||||
}
|
||||
@@ -72,8 +72,9 @@ extern void *CPU_Interrupt_stack_high;
|
||||
* BSP methods that cross file boundaries.
|
||||
*/
|
||||
void bsp_hw_init(void);
|
||||
extern int _sci_get_brparms(
|
||||
tcflag_t cflag,
|
||||
|
||||
int _sci_get_brparms(
|
||||
unsigned int spd,
|
||||
unsigned char *smr,
|
||||
unsigned char *brr
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user