Hi,

I have updated my patchset to enable format string warnings in kernel 
builds. Changes from the first version:

- Regarding pointer differences, this now takes the approach favored by 
kettenis@ and adds support for %td in the kernel but does not add a 
typedef for ptrdiff_t.

- It now removes -Wno-format on amd64 in addition to i386


There are patches mostly broken down by the type of fix at

http://www.sfritsch.de/~stf/openbsd-format-string-v2/

The file 
http://www.sfritsch.de/~stf/openbsd-format-string-v2/combined.patch has 
the whole thing combined (diffstat follows below). I don't think this is 
reviewable when sent as a single mail. But for the most part, the order in 
which the patches are applied does not matter. Therefore I thought that 
people could either review by patch from the above directory or by source 
file from the combined patch, just as they are comfortable. I would then 
commit the patches bit by bit. Or is there a better suggestion?

Once these changes are committed, other gcc4 archs could follow. Gcc2/3 
archs will probably have to keep -Wno-format.

Cheers,
Stefan


Diffstat for combined.patch:

 gnu/gcc/gcc/c-format.c             |    7 ++++---
 sys/arch/amd64/amd64/bios.c        |    2 +-
 sys/arch/amd64/amd64/bus_dma.c     |    8 ++++----
 sys/arch/amd64/amd64/cpu.c         |    2 +-
 sys/arch/amd64/amd64/db_disasm.c   |    4 ++--
 sys/arch/amd64/amd64/identcpu.c    |    2 +-
 sys/arch/amd64/amd64/machdep.c     |    2 +-
 sys/arch/amd64/amd64/pmap.c        |    2 +-
 sys/arch/amd64/amd64/sg_dma.c      |   27 +++++++++++++++++++--------
 sys/arch/amd64/amd64/trap.c        |    8 ++++----
 sys/arch/amd64/conf/Makefile.amd64 |    2 +-
 sys/arch/i386/conf/Makefile.i386   |    2 +-
 sys/arch/i386/i386/bios.c          |    4 ++--
 sys/arch/i386/i386/db_disasm.c     |    2 +-
 sys/arch/i386/i386/db_interface.c  |    4 ++--
 sys/arch/i386/i386/esm.c           |    2 +-
 sys/arch/i386/i386/ioapic.c        |    2 +-
 sys/arch/i386/i386/machdep.c       |    4 ++--
 sys/arch/i386/i386/sg_dma.c        |   26 ++++++++++++++++++--------
 sys/arch/i386/pci/pci_addr_fixup.c |   15 +++++++++------
 sys/arch/i386/pci/pcibios.c        |    6 +++---
 sys/dev/acpi/acpithinkpad.c        |    2 +-
 sys/dev/ic/bwi.c                   |    4 ++--
 sys/dev/ic/mfi.c                   |    5 +++--
 sys/dev/ic/pgt.c                   |    6 +++---
 sys/dev/ic/ti.c                    |    4 ++--
 sys/dev/ipmi.c                     |    4 ++--
 sys/dev/pci/amdiic.c               |    4 ++--
 sys/dev/pci/amdpm.c                |    4 ++--
 sys/dev/pci/bktr/bktr_core.c       |    4 ++--
 sys/dev/pci/drm/i915/i915_gem.c    |   13 +++++++------
 sys/dev/pci/gdt_pci.c              |    4 ++--
 sys/dev/pci/if_iwi.c               |    4 ++--
 sys/dev/pci/if_iwn.c               |   10 +++++-----
 sys/dev/pci/if_lge.c               |    4 ++--
 sys/dev/pci/if_nge.c               |    4 ++--
 sys/dev/pci/if_tl.c                |    2 +-
 sys/dev/pci/if_wb.c                |    2 +-
 sys/dev/pci/if_wpi.c               |    4 ++--
 sys/dev/pci/musycc_obsd.c          |    2 +-
 sys/dev/pci/pci.c                  |   30 ++++++++++++++++++------------
 sys/dev/pci/piixpm.c               |    2 +-
 sys/dev/pci/ubsec.c                |    8 ++++----
 sys/dev/pci/virtio.c               |    6 +++---
 sys/dev/pci/yds.c                  |    2 +-
 sys/dev/pcmcia/if_ep_pcmcia.c      |    3 ++-
 sys/dev/pcmcia/if_malo.c           |    4 +++-
 sys/dev/usb/if_urndis.c            |   10 +++++-----
 sys/dev/vmt.c                      |    4 ++--
 sys/kern/kern_descrip.c            |    4 ++--
 sys/kern/kern_timeout.c            |    2 +-
 sys/kern/subr_disk.c               |   11 ++++++-----
 sys/kern/subr_prf.c                |    6 ++++++
 sys/kern/vfs_cluster.c             |    2 +-
 sys/miscfs/procfs/procfs_status.c  |    4 ++--
 sys/msdosfs/msdosfs_conv.c         |    2 +-
 sys/msdosfs/msdosfs_denode.c       |    2 +-
 sys/msdosfs/msdosfs_vnops.c        |    2 +-
 sys/net/if_spppsubr.c              |    2 +-
 sys/netinet/ip_output.c            |    2 +-
 sys/netinet6/ip6_forward.c         |    2 +-
 sys/netinet6/ip6_output.c          |    2 +-
 sys/nfs/nfs_socket.c               |    4 ++--
 63 files changed, 189 insertions(+), 146 deletions(-)

Reply via email to