blob: b132ea665b03ad9d9fb9872b09a15bff716ecfe3 [file] [log] [blame]
// Copyright 2023 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
using Antmicro.Renode.Core;
using Antmicro.Renode.Logging;
using Antmicro.Renode.Peripherals.Bus;
// All this stub does is mark an address range as always returning a fixed
// value.
namespace Antmicro.Renode.Peripherals
{
public class AddressRangeStub : IDoubleWordPeripheral, IKnownSize
{
public AddressRangeStub(long size, uint value)
{
this.size = size;
this.value = value;
}
public void Reset()
{
}
public uint ReadDoubleWord(long offset)
{
return this.value;
}
public void WriteDoubleWord(long offset, uint value)
{
}
public long Size { get { return this.size; } }
long size;
uint value;
}
}