svn commit: r291395 - head/sys/dev/sfxge/common
Andrew Rybchenko
arybchik at FreeBSD.org
Fri Nov 27 16:16:47 UTC 2015
Author: arybchik
Date: Fri Nov 27 16:16:45 2015
New Revision: 291395
URL: https://svnweb.freebsd.org/changeset/base/291395
Log:
sfxge: cleanup: fix prefast annotations for stats buffers
Submitted by: Andy Moreton <amoreton at solarflare.com>
Sponsored by: Solarflare Communications, Inc.
MFC after: 2 days
Modified:
head/sys/dev/sfxge/common/efx.h
head/sys/dev/sfxge/common/efx_mon.c
head/sys/dev/sfxge/common/efx_phy.c
head/sys/dev/sfxge/common/hunt_impl.h
head/sys/dev/sfxge/common/hunt_mac.c
head/sys/dev/sfxge/common/hunt_phy.c
head/sys/dev/sfxge/common/mcdi_mon.c
head/sys/dev/sfxge/common/mcdi_mon.h
head/sys/dev/sfxge/common/siena_impl.h
head/sys/dev/sfxge/common/siena_mac.c
head/sys/dev/sfxge/common/siena_phy.c
Modified: head/sys/dev/sfxge/common/efx.h
==============================================================================
--- head/sys/dev/sfxge/common/efx.h Fri Nov 27 16:07:20 2015 (r291394)
+++ head/sys/dev/sfxge/common/efx.h Fri Nov 27 16:16:45 2015 (r291395)
@@ -688,7 +688,7 @@ extern __checkReturn int
efx_mon_stats_update(
__in efx_nic_t *enp,
__in efsys_mem_t *esmp,
- __out_ecount(EFX_MON_NSTATS) efx_mon_stat_value_t *values);
+ __inout_ecount(EFX_MON_NSTATS) efx_mon_stat_value_t *values);
#endif /* EFSYS_OPT_MON_STATS */
@@ -946,7 +946,7 @@ extern __checkReturn int
efx_phy_stats_update(
__in efx_nic_t *enp,
__in efsys_mem_t *esmp,
- __out_ecount(EFX_PHY_NSTATS) uint32_t *stat);
+ __inout_ecount(EFX_PHY_NSTATS) uint32_t *stat);
#endif /* EFSYS_OPT_PHY_STATS */
Modified: head/sys/dev/sfxge/common/efx_mon.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_mon.c Fri Nov 27 16:07:20 2015 (r291394)
+++ head/sys/dev/sfxge/common/efx_mon.c Fri Nov 27 16:16:45 2015 (r291395)
@@ -307,7 +307,7 @@ efx_mon_stat_name(
efx_mon_stats_update(
__in efx_nic_t *enp,
__in efsys_mem_t *esmp,
- __out_ecount(EFX_MON_NSTATS) efx_mon_stat_value_t *values)
+ __inout_ecount(EFX_MON_NSTATS) efx_mon_stat_value_t *values)
{
efx_mon_t *emp = &(enp->en_mon);
efx_mon_ops_t *emop = emp->em_emop;
Modified: head/sys/dev/sfxge/common/efx_phy.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_phy.c Fri Nov 27 16:07:20 2015 (r291394)
+++ head/sys/dev/sfxge/common/efx_phy.c Fri Nov 27 16:16:45 2015 (r291395)
@@ -631,7 +631,7 @@ efx_phy_stat_name(
efx_phy_stats_update(
__in efx_nic_t *enp,
__in efsys_mem_t *esmp,
- __out_ecount(EFX_PHY_NSTATS) uint32_t *stat)
+ __inout_ecount(EFX_PHY_NSTATS) uint32_t *stat)
{
efx_port_t *epp = &(enp->en_port);
efx_phy_ops_t *epop = epp->ep_epop;
Modified: head/sys/dev/sfxge/common/hunt_impl.h
==============================================================================
--- head/sys/dev/sfxge/common/hunt_impl.h Fri Nov 27 16:07:20 2015 (r291394)
+++ head/sys/dev/sfxge/common/hunt_impl.h Fri Nov 27 16:16:45 2015 (r291395)
@@ -236,7 +236,7 @@ extern __checkReturn int
hunt_mac_stats_update(
__in efx_nic_t *enp,
__in efsys_mem_t *esmp,
- __out_ecount(EFX_MAC_NSTATS) efsys_stat_t *stat,
+ __inout_ecount(EFX_MAC_NSTATS) efsys_stat_t *stat,
__out_opt uint32_t *generationp);
#endif /* EFSYS_OPT_MAC_STATS */
@@ -485,7 +485,7 @@ extern __checkReturn int
hunt_phy_stats_update(
__in efx_nic_t *enp,
__in efsys_mem_t *esmp,
- __out_ecount(EFX_PHY_NSTATS) uint32_t *stat);
+ __inout_ecount(EFX_PHY_NSTATS) uint32_t *stat);
#endif /* EFSYS_OPT_PHY_STATS */
Modified: head/sys/dev/sfxge/common/hunt_mac.c
==============================================================================
--- head/sys/dev/sfxge/common/hunt_mac.c Fri Nov 27 16:07:20 2015 (r291394)
+++ head/sys/dev/sfxge/common/hunt_mac.c Fri Nov 27 16:16:45 2015 (r291395)
@@ -371,7 +371,7 @@ fail1:
hunt_mac_stats_update(
__in efx_nic_t *enp,
__in efsys_mem_t *esmp,
- __out_ecount(EFX_MAC_NSTATS) efsys_stat_t *stat,
+ __inout_ecount(EFX_MAC_NSTATS) efsys_stat_t *stat,
__out_opt uint32_t *generationp)
{
efx_qword_t value;
Modified: head/sys/dev/sfxge/common/hunt_phy.c
==============================================================================
--- head/sys/dev/sfxge/common/hunt_phy.c Fri Nov 27 16:07:20 2015 (r291394)
+++ head/sys/dev/sfxge/common/hunt_phy.c Fri Nov 27 16:16:45 2015 (r291395)
@@ -495,7 +495,7 @@ hunt_phy_oui_get(
hunt_phy_stats_update(
__in efx_nic_t *enp,
__in efsys_mem_t *esmp,
- __out_ecount(EFX_PHY_NSTATS) uint32_t *stat)
+ __inout_ecount(EFX_PHY_NSTATS) uint32_t *stat)
{
/* TBD: no stats support in firmware yet */
_NOTE(ARGUNUSED(enp, esmp))
Modified: head/sys/dev/sfxge/common/mcdi_mon.c
==============================================================================
--- head/sys/dev/sfxge/common/mcdi_mon.c Fri Nov 27 16:07:20 2015 (r291394)
+++ head/sys/dev/sfxge/common/mcdi_mon.c Fri Nov 27 16:16:45 2015 (r291395)
@@ -162,7 +162,7 @@ mcdi_mon_decode_stats(
__in size_t sensor_mask_size,
__in_opt efsys_mem_t *esmp,
__out_ecount_opt(sensor_mask_size) uint32_t *stat_maskp,
- __out_ecount_opt(EFX_MON_NSTATS) efx_mon_stat_value_t *stat)
+ __inout_ecount_opt(EFX_MON_NSTATS) efx_mon_stat_value_t *stat)
{
efx_mcdi_iface_t *emip = &(enp->en_mcdi.em_emip);
uint16_t port_mask;
@@ -435,7 +435,7 @@ fail1:
mcdi_mon_stats_update(
__in efx_nic_t *enp,
__in efsys_mem_t *esmp,
- __out_ecount(EFX_MON_NSTATS) efx_mon_stat_value_t *values)
+ __inout_ecount(EFX_MON_NSTATS) efx_mon_stat_value_t *values)
{
efx_nic_cfg_t *encp = &(enp->en_nic_cfg);
uint32_t size = encp->enc_mon_stat_dma_buf_size;
Modified: head/sys/dev/sfxge/common/mcdi_mon.h
==============================================================================
--- head/sys/dev/sfxge/common/mcdi_mon.h Fri Nov 27 16:07:20 2015 (r291394)
+++ head/sys/dev/sfxge/common/mcdi_mon.h Fri Nov 27 16:16:45 2015 (r291395)
@@ -63,7 +63,7 @@ extern __checkReturn int
mcdi_mon_stats_update(
__in efx_nic_t *enp,
__in efsys_mem_t *esmp,
- __out_ecount(EFX_MON_NSTATS) efx_mon_stat_value_t *values);
+ __inout_ecount(EFX_MON_NSTATS) efx_mon_stat_value_t *values);
#endif /* EFSYS_OPT_MON_STATS */
Modified: head/sys/dev/sfxge/common/siena_impl.h
==============================================================================
--- head/sys/dev/sfxge/common/siena_impl.h Fri Nov 27 16:07:20 2015 (r291394)
+++ head/sys/dev/sfxge/common/siena_impl.h Fri Nov 27 16:16:45 2015 (r291395)
@@ -472,7 +472,7 @@ extern __checkReturn int
siena_mac_stats_update(
__in efx_nic_t *enp,
__in efsys_mem_t *esmp,
- __out_ecount(EFX_MAC_NSTATS) efsys_stat_t *stat,
+ __inout_ecount(EFX_MAC_NSTATS) efsys_stat_t *stat,
__out_opt uint32_t *generationp);
#endif /* EFSYS_OPT_MAC_STATS */
Modified: head/sys/dev/sfxge/common/siena_mac.c
==============================================================================
--- head/sys/dev/sfxge/common/siena_mac.c Fri Nov 27 16:07:20 2015 (r291394)
+++ head/sys/dev/sfxge/common/siena_mac.c Fri Nov 27 16:16:45 2015 (r291395)
@@ -234,7 +234,7 @@ fail1:
siena_mac_stats_update(
__in efx_nic_t *enp,
__in efsys_mem_t *esmp,
- __out_ecount(EFX_MAC_NSTATS) efsys_stat_t *stat,
+ __inout_ecount(EFX_MAC_NSTATS) efsys_stat_t *stat,
__out_opt uint32_t *generationp)
{
efx_qword_t value;
Modified: head/sys/dev/sfxge/common/siena_phy.c
==============================================================================
--- head/sys/dev/sfxge/common/siena_phy.c Fri Nov 27 16:07:20 2015 (r291394)
+++ head/sys/dev/sfxge/common/siena_phy.c Fri Nov 27 16:16:45 2015 (r291395)
@@ -466,7 +466,7 @@ siena_phy_decode_stats(
__in uint32_t vmask,
__in_opt efsys_mem_t *esmp,
__out_opt uint64_t *smaskp,
- __out_ecount_opt(EFX_PHY_NSTATS) uint32_t *stat)
+ __inout_ecount_opt(EFX_PHY_NSTATS) uint32_t *stat)
{
uint64_t smask = 0;
@@ -550,7 +550,7 @@ siena_phy_decode_stats(
siena_phy_stats_update(
__in efx_nic_t *enp,
__in efsys_mem_t *esmp,
- __out_ecount(EFX_PHY_NSTATS) uint32_t *stat)
+ __inout_ecount(EFX_PHY_NSTATS) uint32_t *stat)
{
efx_nic_cfg_t *encp = &(enp->en_nic_cfg);
uint32_t vmask = encp->enc_mcdi_phy_stat_mask;
More information about the svn-src-head
mailing list