-/*!
+/**
* \file
* <!--
+ * This file is part of BeRTOS.
+ *
+ * Bertos 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ * As a special exception, you may use this file as part of a free software
+ * library without restriction. Specifically, if other files instantiate
+ * templates or use macros or inline functions from this file, or you compile
+ * this file and link it with other files to produce an executable, this
+ * file does not by itself cause the resulting executable to be covered by
+ * the GNU General Public License. This exception does not however
+ * invalidate any other reasons why the executable file might be covered by
+ * the GNU General Public License.
+ *
* Copyright 2003, 2004 Develer S.r.l. (http://www.develer.com/)
- * This file is part of DevLib - See devlib/README for information.
+ *
* -->
*
* \version $Id$
/*#*
*#* $Log$
+ *#* Revision 1.14 2006/07/19 12:56:26 bernie
+ *#* Convert to new Doxygen style.
+ *#*
+ *#* Revision 1.13 2005/11/04 16:20:02 bernie
+ *#* Fix reference to README.devlib in header.
+ *#*
+ *#* Revision 1.12 2005/04/11 19:10:27 bernie
+ *#* Include top-level headers from cfg/ subdir.
+ *#*
+ *#* Revision 1.11 2005/01/25 07:42:04 bernie
+ *#* Simplify.
+ *#*
*#* Revision 1.10 2005/01/14 00:48:33 aleph
*#* Rename callbacks; SerialHardwareVT.txSending: New callback.
*#*
#include "ser.h"
#include "ser_p.h"
#include <drv/irq.h>
-#include <debug.h>
+#include <cfg/debug.h>
#include <hw.h>
#include <DSP56F807.h>
static inline void disable_tx_irq(struct SerialHardware* _hw)
{
struct SCI* hw = (struct SCI*)_hw;
- volatile struct REG_SCI_STRUCT* regs = hw->regs;
- disable_tx_irq_bare(regs);
+ disable_tx_irq_bare(hw->regs);
}
static inline void disable_rx_irq(struct SerialHardware* _hw)
{
struct SCI* hw = (struct SCI*)_hw;
- volatile struct REG_SCI_STRUCT* regs = hw->regs;
- disable_rx_irq_bare(regs);
+ disable_rx_irq_bare(hw->regs);
}
static inline void enable_tx_irq(struct SerialHardware* _hw)
{
struct SCI* hw = (struct SCI*)_hw;
- volatile struct REG_SCI_STRUCT* regs = hw->regs;
- enable_tx_irq_bare(regs);
+ enable_tx_irq_bare(hw->regs);
}
static inline void enable_rx_irq(struct SerialHardware* _hw)
{
struct SCI* hw = (struct SCI*)_hw;
- volatile struct REG_SCI_STRUCT* regs = hw->regs;
- enable_rx_irq_bare(regs);
+ enable_rx_irq_bare(hw->regs);
}
static inline bool tx_irq_enabled(struct SerialHardware* _hw)
{
struct SCI* hw = (struct SCI*)_hw;
- volatile struct REG_SCI_STRUCT* regs = hw->regs;
- return (regs->CR & REG_SCI_CR_TEIE);
+ return (hw->regs->CR & REG_SCI_CR_TEIE);
}
static void tx_isr(const struct SCI *hw)