From: Stefan E. <se...@us...> - 2002-04-23 13:30:03
|
Update of /cvsroot/blob/blob/src/blob In directory usw-pr-cvs1:/tmp/cvs-serv21305/src/blob Added Files: trizeps.c Log Message: - AGAIN forgot to add important files. Dammit. --- NEW FILE: trizeps.c --- /* * trizeps.c: Keith & Koep Trizeps specific stuff * * Copyright (C) 2001 Erik Mouw (J.A...@it...) * Copyright (C) 2001 Stefan Eletzhofer * (ste...@ww...) * Copyright (C) 2002 Wolfgang Müller (wol...@ds...) * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #ident "$Id: trizeps.c,v 1.1 2002/04/23 13:29:57 seletz Exp $" /********************************************************************** * includes */ #ifdef HAVE_CONFIG_H # include <blob/config.h> #endif #include <blob/main.h> #include <blob/arch.h> #include <blob/errno.h> #include <blob/error.h> #include <blob/util.h> #include <blob/serial.h> #include <blob/flash.h> #include <blob/init.h> #include <blob/command.h> #include <blob/uucodec.h> #include <blob/serial.h> /* oops, agen */ /********************************************************************** * defines */ /* this will send a cold shiver through erik's spine ... */ #define ERR( x ) { ret = x; goto DONE; } /* more readable IMHO */ #define MEM( x ) (*((u32 *)x)) /********************************************************************** * globals */ extern blob_status_t blob_status; /********************************************************************** * module globals */ /* flash descriptor for Trizeps flash */ /* Trizeps uses 1x Intel 28F256J3A strataflash (16MB) */ static const flash_descriptor_t trizeps_flash_descriptors[] = { { /* http://developer.intel.com/design/flcomp/datashts/29066710.pdf */ size: 1 * 128 * 1024, /* 1 chip, 128KB blocks */ num: 128, /* 128 blocks */ lockable: 1 }, { /* NULL block */ }, }; /********************************************************************** * static functions */ static int trizeps_flash_enable_vpp(void) { return 0; } static int trizeps_flash_disable_vpp(void) { return 0; } static void init_trizeps_flash_driver(void) { flash_descriptors = trizeps_flash_descriptors; flash_driver = &intel16_flash_driver; flash_driver->enable_vpp = trizeps_flash_enable_vpp; flash_driver->disable_vpp = trizeps_flash_disable_vpp; } __initlist(init_trizeps_flash_driver, INIT_LEVEL_DRIVER_SELECTION); static void trizeps_init_hardware(void) { /* select serial driver */ serial_driver = &sa11x0_serial_driver; } __initlist(trizeps_init_hardware, INIT_LEVEL_DRIVER_SELECTION); /* eof */ |