Skip to content

Commit

Permalink
[rtl] minor comment cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
stnolting committed Jun 1, 2024
1 parent b3f039b commit 28ccc25
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 43 deletions.
3 changes: 1 addition & 2 deletions rtl/core/neorv32_cache.vhd
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@
-- SPDX-License-Identifier: BSD-3-Clause --
-- ================================================================================ --


library ieee;
use ieee.std_logic_1164.all;
use ieee.numeric_std.all;
Expand Down Expand Up @@ -685,7 +684,7 @@ begin

-- Access Status (1 Cycle Latency) --------------------------------------------------------
-- -------------------------------------------------------------------------------------------
hit_o <= '1' when (valid_mem_rd = '1') and (acc_tag_ff = tag_mem_rd) else '0'; -- cache access hit
hit_o <= '1' when (valid_mem_rd = '1') and (tag_mem_rd = acc_tag_ff) else '0'; -- cache access hit
dirty_o <= '1' when (valid_mem_rd = '1') and (dirty_mem_rd = '1') and (READ_ONLY = false) else '0'; -- accessed block is dirty

-- base address of accessed block --
Expand Down
11 changes: 3 additions & 8 deletions rtl/core/neorv32_gpio.vhd
Original file line number Diff line number Diff line change
Expand Up @@ -50,18 +50,14 @@ begin
bus_rsp_o.err <= '0';
bus_rsp_o.data <= (others => '0');
if (bus_req_i.stb = '1') then

-- write access --
if (bus_req_i.rw = '1') then
if (bus_req_i.rw = '1') then -- write access
if (bus_req_i.addr(3 downto 2) = "10") then
dout(31 downto 00) <= bus_req_i.data;
end if;
if (bus_req_i.addr(3 downto 2) = "11") then
dout(63 downto 32) <= bus_req_i.data;
end if;

-- read access --
else
else -- read access
case bus_req_i.addr(3 downto 2) is
when "00" => bus_rsp_o.data <= din_rd(31 downto 00);
when "01" => bus_rsp_o.data <= din_rd(63 downto 32);
Expand All @@ -79,7 +75,6 @@ begin
-- -------------------------------------------------------------------------------------------
pin_mapping: process(din, dout)
begin
-- defaults --
din_rd <= (others => '0');
dout_rd <= (others => '0');
for i in 0 to GPIO_NUM-1 loop
Expand All @@ -97,7 +92,7 @@ begin
if (rstn_i = '0') then
din <= (others => '0');
elsif rising_edge(clk_i) then
din <= gpio_i; -- to prevent metastability
din <= gpio_i;
end if;
end process input_sync;

Expand Down
43 changes: 10 additions & 33 deletions rtl/core/neorv32_xip.vhd
Original file line number Diff line number Diff line change
Expand Up @@ -402,38 +402,15 @@ end neorv32_xip_rtl;
-- ############################################################################################################################


-- #################################################################################################
-- # << NEORV32 - XIP Module - SPI Physical Interface >> #
-- # ********************************************************************************************* #
-- # BSD 3-Clause License #
-- # #
-- # The NEORV32 RISC-V Processor, https://github.com/stnolting/neorv32 #
-- # Copyright (c) 2024, Stephan Nolting. All rights reserved. #
-- # #
-- # Redistribution and use in source and binary forms, with or without modification, are #
-- # permitted provided that the following conditions are met: #
-- # #
-- # 1. Redistributions of source code must retain the above copyright notice, this list of #
-- # conditions and the following disclaimer. #
-- # #
-- # 2. Redistributions in binary form must reproduce the above copyright notice, this list of #
-- # conditions and the following disclaimer in the documentation and/or other materials #
-- # provided with the distribution. #
-- # #
-- # 3. Neither the name of the copyright holder nor the names of its contributors may be used to #
-- # endorse or promote products derived from this software without specific prior written #
-- # permission. #
-- # #
-- # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS #
-- # OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF #
-- # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE #
-- # COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, #
-- # EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE #
-- # GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED #
-- # AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING #
-- # NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED #
-- # OF THE POSSIBILITY OF SUCH DAMAGE. #
-- #################################################################################################
-- ================================================================================ --
-- NEORV32 SoC - XIP Module - SPI Physical Interface --
-- -------------------------------------------------------------------------------- --
-- The NEORV32 RISC-V Processor - https://github.com/stnolting/neorv32 --
-- Copyright (c) NEORV32 contributors. --
-- Copyright (c) 2020 - 2024 Stephan Nolting. All rights reserved. --
-- Licensed under the BSD-3-Clause license, see LICENSE for details. --
-- SPDX-License-Identifier: BSD-3-Clause --
-- ================================================================================ --

library ieee;
use ieee.std_logic_1164.all;
Expand All @@ -457,7 +434,7 @@ entity neorv32_xip_phy is
op_final_i : in std_ulogic; -- end current transmission
op_csen_i : in std_ulogic; -- actually enabled device for transmission
op_busy_o : out std_ulogic; -- transmission in progress when set
op_nbytes_i : in std_ulogic_vector(03 downto 0); -- actual number of bytes to transmit (1..9)
op_nbytes_i : in std_ulogic_vector(3 downto 0); -- actual number of bytes to transmit (1..9)
op_wdata_i : in std_ulogic_vector(71 downto 0); -- write data
op_rdata_o : out std_ulogic_vector(31 downto 0); -- read data
-- SPI interface --
Expand Down

0 comments on commit 28ccc25

Please sign in to comment.