Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 05 Jan 2014 13:51:10 -0500
From:      Nathan Whitehorn <nwhitehorn@freebsd.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   Re: svn commit: r260327 - in head/sys: arm/arm arm/include arm/mv dev/fdt dev/uart mips/include powerpc/include x86/include
Message-ID:  <52C9A99E.80400@freebsd.org>
In-Reply-To: <201401051846.s05IkwE3022468@svn.freebsd.org>
References:  <201401051846.s05IkwE3022468@svn.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On 01/05/14 13:46, Nathan Whitehorn wrote:
> Author: nwhitehorn Date: Sun Jan  5 18:46:58 2014 New Revision:
> 260327 URL: http://svnweb.freebsd.org/changeset/base/260327
>
> Log: Retire machine/fdt.h as a header used by MI code, as its
> function is now obsolete. This involves the following pieces: -
> Remove it entirely on PowerPC, where it is not used by MD code
> either - Remove all references to machine/fdt.h in
> non-architecture-specific code (aside from uart_cpu_fdt.c, shared by
> ARM and MIPS, and so is somewhat non-arch-specific). - Fix code
> relying on header pollution from machine/fdt.h includes - Legacy
> fdtbus.c (still used on x86 FDT systems) now passes resource requests
> to its parent (nexus). This allows x86 FDT devices to allocate both
> memory and IO requests and removes the last notionally MI use of
> fdtbus_bs_tag. - On those architectures that retain a machine/fdt.h,
> unused bits like FDT_MAP_IRQ and FDT_INTR_MAX have been removed.
>

A few extra notes from while I was doing this:

#1:
dev/fdt/fdt_pci.c is not actually MI. In fact, it is used only by
arm/mv/mv_pci.c and contains a large number of implementation details
thereof. Perhaps it should be moved into arm/mv.

#2:
fdtbus_bs_tag (and machine/fdt.h) are still used from uart_cpu_fdt.c,
which is used by ARM and MIPS. Maybe this should be looked at some.
Since this file is specific to those architectures anyway, and they use
it extensively, it's not a big deal.

#3:
Nearly every architecture in the tree is currently separately declaring
an identical struct mem_region, which is a combination of a vm_offset_t
and a vm_size_t. These should be centralized. The vm_offset_t should
also be a vm_paddr_t.

#4:
uart_bus_fdt.c really has nothing to do with FDT per se: it's just the
simplebus attachment for uart(4). It should probably be renamed to
uart_bus_simplebus.c or the like or split up into its constituent UART
drivers.
-Nathan






Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?52C9A99E.80400>