* [PATCH v3 07/15] soc: octeontx2: Scan blocks for LFs provisioned to PF/VF
From: sunil.kovvuri @ 2018-09-04 16:28 UTC (permalink / raw)
To: linux-kernel, arnd, olof
Cc: linux-arm-kernel, linux-soc, andrew, davem, netdev, Sunil Goutham
In-Reply-To: <1536078525-31534-1-git-send-email-sunil.kovvuri@gmail.com>
From: Sunil Goutham <sgoutham@marvell.com>
Scan all RVU blocks to find any 'LF to RVU PF/VF' mapping done by
low level firmware. If found any, mark them as used in respective
block's LF bitmap and also save mapped PF/VF's PF_FUNC info.
This is done to avoid reattaching a block LF to a different RVU PF/VF.
Signed-off-by: Sunil Goutham <sgoutham@marvell.com>
---
drivers/soc/marvell/octeontx2/rvu.c | 148 ++++++++++++++++++++++++++++-
drivers/soc/marvell/octeontx2/rvu.h | 16 ++++
drivers/soc/marvell/octeontx2/rvu_struct.h | 18 ++++
3 files changed, 180 insertions(+), 2 deletions(-)
diff --git a/drivers/soc/marvell/octeontx2/rvu.c b/drivers/soc/marvell/octeontx2/rvu.c
index 25f79bf..9539ab9 100644
--- a/drivers/soc/marvell/octeontx2/rvu.c
+++ b/drivers/soc/marvell/octeontx2/rvu.c
@@ -22,6 +22,8 @@
#define DRV_STRING "Marvell OcteonTX2 RVU Admin Function Driver"
#define DRV_VERSION "1.0"
+static int rvu_get_hwvf(struct rvu *rvu, int pcifunc);
+
/* Supported devices */
static const struct pci_device_id rvu_id_table[] = {
{ PCI_DEVICE(PCI_VENDOR_ID_CAVIUM, PCI_DEVID_OCTEONTX2_RVU_AF) },
@@ -66,6 +68,91 @@ int rvu_alloc_bitmap(struct rsrc_bmap *rsrc)
return 0;
}
+static void rvu_update_rsrc_map(struct rvu *rvu, struct rvu_pfvf *pfvf,
+ struct rvu_block *block, u16 pcifunc,
+ u16 lf, bool attach)
+{
+ int devnum, num_lfs = 0;
+ bool is_pf;
+ u64 reg;
+
+ if (lf >= block->lf.max) {
+ dev_err(&rvu->pdev->dev,
+ "%s: FATAL: LF %d is >= %s's max lfs i.e %d\n",
+ __func__, lf, block->name, block->lf.max);
+ return;
+ }
+
+ /* Check if this is for a RVU PF or VF */
+ if (pcifunc & RVU_PFVF_FUNC_MASK) {
+ is_pf = false;
+ devnum = rvu_get_hwvf(rvu, pcifunc);
+ } else {
+ is_pf = true;
+ devnum = rvu_get_pf(pcifunc);
+ }
+
+ block->fn_map[lf] = attach ? pcifunc : 0;
+
+ switch (block->type) {
+ case BLKTYPE_NPA:
+ pfvf->npalf = attach ? true : false;
+ num_lfs = pfvf->npalf;
+ break;
+ case BLKTYPE_NIX:
+ pfvf->nixlf = attach ? true : false;
+ num_lfs = pfvf->nixlf;
+ break;
+ case BLKTYPE_SSO:
+ attach ? pfvf->sso++ : pfvf->sso--;
+ num_lfs = pfvf->sso;
+ break;
+ case BLKTYPE_SSOW:
+ attach ? pfvf->ssow++ : pfvf->ssow--;
+ num_lfs = pfvf->ssow;
+ break;
+ case BLKTYPE_TIM:
+ attach ? pfvf->timlfs++ : pfvf->timlfs--;
+ num_lfs = pfvf->timlfs;
+ break;
+ case BLKTYPE_CPT:
+ attach ? pfvf->cptlfs++ : pfvf->cptlfs--;
+ num_lfs = pfvf->cptlfs;
+ break;
+ }
+
+ reg = is_pf ? block->pf_lfcnt_reg : block->vf_lfcnt_reg;
+ rvu_write64(rvu, BLKADDR_RVUM, reg | (devnum << 16), num_lfs);
+}
+
+inline int rvu_get_pf(u16 pcifunc)
+{
+ return (pcifunc >> RVU_PFVF_PF_SHIFT) & RVU_PFVF_PF_MASK;
+}
+
+static int rvu_get_hwvf(struct rvu *rvu, int pcifunc)
+{
+ int pf, func;
+ u64 cfg;
+
+ pf = rvu_get_pf(pcifunc);
+ func = pcifunc & RVU_PFVF_FUNC_MASK;
+
+ /* Get first HWVF attached to this PF */
+ cfg = rvu_read64(rvu, BLKADDR_RVUM, RVU_PRIV_PFX_CFG(pf));
+
+ return ((cfg & 0xFFF) + func - 1);
+}
+
+struct rvu_pfvf *rvu_get_pfvf(struct rvu *rvu, int pcifunc)
+{
+ /* Check if it is a PF or VF */
+ if (pcifunc & RVU_PFVF_FUNC_MASK)
+ return &rvu->hwvf[rvu_get_hwvf(rvu, pcifunc)];
+ else
+ return &rvu->pf[rvu_get_pf(pcifunc)];
+}
+
static void rvu_check_block_implemented(struct rvu *rvu)
{
struct rvu_hwinfo *hw = rvu->hw;
@@ -107,6 +194,28 @@ static void rvu_reset_all_blocks(struct rvu *rvu)
rvu_block_reset(rvu, BLKADDR_NDC2, NDC_AF_BLK_RST);
}
+static void rvu_scan_block(struct rvu *rvu, struct rvu_block *block)
+{
+ struct rvu_pfvf *pfvf;
+ u64 cfg;
+ int lf;
+
+ for (lf = 0; lf < block->lf.max; lf++) {
+ cfg = rvu_read64(rvu, block->addr,
+ block->lfcfg_reg | (lf << block->lfshift));
+ if (!(cfg & BIT_ULL(63)))
+ continue;
+
+ /* Set this resource as being used */
+ __set_bit(lf, block->lf.bmap);
+
+ /* Get, to whom this LF is attached */
+ pfvf = rvu_get_pfvf(rvu, (cfg >> 8) & 0xFFFF);
+ rvu_update_rsrc_map(rvu, pfvf, block,
+ (cfg >> 8) & 0xFFFF, lf, true);
+ }
+}
+
static void rvu_free_hw_resources(struct rvu *rvu)
{
struct rvu_hwinfo *hw = rvu->hw;
@@ -124,7 +233,7 @@ static int rvu_setup_hw_resources(struct rvu *rvu)
{
struct rvu_hwinfo *hw = rvu->hw;
struct rvu_block *block;
- int err;
+ int blkid, err;
u64 cfg;
/* Get HW supported max RVU PF & VF count */
@@ -140,6 +249,7 @@ static int rvu_setup_hw_resources(struct rvu *rvu)
cfg = rvu_read64(rvu, BLKADDR_NPA, NPA_AF_CONST);
block->lf.max = (cfg >> 16) & 0xFFF;
block->addr = BLKADDR_NPA;
+ block->type = BLKTYPE_NPA;
block->lfshift = 8;
block->lookup_reg = NPA_AF_RVU_LF_CFG_DEBUG;
block->pf_lfcnt_reg = RVU_PRIV_PFX_NPA_CFG;
@@ -160,6 +270,7 @@ static int rvu_setup_hw_resources(struct rvu *rvu)
cfg = rvu_read64(rvu, BLKADDR_NIX0, NIX_AF_CONST2);
block->lf.max = cfg & 0xFFF;
block->addr = BLKADDR_NIX0;
+ block->type = BLKTYPE_NIX;
block->lfshift = 8;
block->lookup_reg = NIX_AF_RVU_LF_CFG_DEBUG;
block->pf_lfcnt_reg = RVU_PRIV_PFX_NIX_CFG;
@@ -180,6 +291,7 @@ static int rvu_setup_hw_resources(struct rvu *rvu)
cfg = rvu_read64(rvu, BLKADDR_SSO, SSO_AF_CONST);
block->lf.max = cfg & 0xFFFF;
block->addr = BLKADDR_SSO;
+ block->type = BLKTYPE_SSO;
block->multislot = true;
block->lfshift = 3;
block->lookup_reg = SSO_AF_RVU_LF_CFG_DEBUG;
@@ -200,6 +312,7 @@ static int rvu_setup_hw_resources(struct rvu *rvu)
goto tim;
block->lf.max = (cfg >> 56) & 0xFF;
block->addr = BLKADDR_SSOW;
+ block->type = BLKTYPE_SSOW;
block->multislot = true;
block->lfshift = 3;
block->lookup_reg = SSOW_AF_RVU_LF_HWS_CFG_DEBUG;
@@ -221,6 +334,7 @@ static int rvu_setup_hw_resources(struct rvu *rvu)
cfg = rvu_read64(rvu, BLKADDR_TIM, TIM_AF_CONST);
block->lf.max = cfg & 0xFFFF;
block->addr = BLKADDR_TIM;
+ block->type = BLKTYPE_TIM;
block->multislot = true;
block->lfshift = 3;
block->lookup_reg = TIM_AF_RVU_LF_CFG_DEBUG;
@@ -238,10 +352,11 @@ static int rvu_setup_hw_resources(struct rvu *rvu)
/* Init CPT LF's bitmap */
block = &hw->block[BLKADDR_CPT0];
if (!block->implemented)
- return 0;
+ goto init;
cfg = rvu_read64(rvu, BLKADDR_CPT0, CPT_AF_CONSTANTS0);
block->lf.max = cfg & 0xFF;
block->addr = BLKADDR_CPT0;
+ block->type = BLKTYPE_CPT;
block->multislot = true;
block->lfshift = 3;
block->lookup_reg = CPT_AF_RVU_LF_CFG_DEBUG;
@@ -255,6 +370,35 @@ static int rvu_setup_hw_resources(struct rvu *rvu)
if (err)
return err;
+init:
+ /* Allocate memory for PFVF data */
+ rvu->pf = devm_kcalloc(rvu->dev, hw->total_pfs,
+ sizeof(struct rvu_pfvf), GFP_KERNEL);
+ if (!rvu->pf)
+ return -ENOMEM;
+
+ rvu->hwvf = devm_kcalloc(rvu->dev, hw->total_vfs,
+ sizeof(struct rvu_pfvf), GFP_KERNEL);
+ if (!rvu->hwvf)
+ return -ENOMEM;
+
+ for (blkid = 0; blkid < BLK_COUNT; blkid++) {
+ block = &hw->block[blkid];
+ if (!block->lf.bmap)
+ continue;
+
+ /* Allocate memory for block LF/slot to pcifunc mapping info */
+ block->fn_map = devm_kcalloc(rvu->dev, block->lf.max,
+ sizeof(u16), GFP_KERNEL);
+ if (!block->fn_map)
+ return -ENOMEM;
+
+ /* Scan all blocks to check if low level firmware has
+ * already provisioned any of the resources to a PF/VF.
+ */
+ rvu_scan_block(rvu, block);
+ }
+
return 0;
}
diff --git a/drivers/soc/marvell/octeontx2/rvu.h b/drivers/soc/marvell/octeontx2/rvu.h
index 2fb9407..ce9897b 100644
--- a/drivers/soc/marvell/octeontx2/rvu.h
+++ b/drivers/soc/marvell/octeontx2/rvu.h
@@ -42,9 +42,11 @@ struct rsrc_bmap {
struct rvu_block {
struct rsrc_bmap lf;
+ u16 *fn_map; /* LF to pcifunc mapping */
bool multislot;
bool implemented;
u8 addr; /* RVU_BLOCK_ADDR_E */
+ u8 type; /* RVU_BLOCK_TYPE_E */
u8 lfshift;
u64 lookup_reg;
u64 pf_lfcnt_reg;
@@ -55,6 +57,16 @@ struct rvu_block {
unsigned char name[NAME_SIZE];
};
+/* Structure for per RVU func info ie PF/VF */
+struct rvu_pfvf {
+ bool npalf; /* Only one NPALF per RVU_FUNC */
+ bool nixlf; /* Only one NIXLF per RVU_FUNC */
+ u16 sso;
+ u16 ssow;
+ u16 cptlfs;
+ u16 timlfs;
+};
+
struct rvu_hwinfo {
u8 total_pfs; /* MAX RVU PFs HW supports */
u16 total_vfs; /* Max RVU VFs HW supports */
@@ -69,6 +81,8 @@ struct rvu {
struct pci_dev *pdev;
struct device *dev;
struct rvu_hwinfo *hw;
+ struct rvu_pfvf *pf;
+ struct rvu_pfvf *hwvf;
/* Mbox */
struct otx2_mbox mbox;
@@ -107,5 +121,7 @@ static inline u64 rvupf_read64(struct rvu *rvu, u64 offset)
int rvu_alloc_bitmap(struct rsrc_bmap *rsrc);
int rvu_poll_reg(struct rvu *rvu, u64 block, u64 offset, u64 mask, bool zero);
+int rvu_get_pf(u16 pcifunc);
+struct rvu_pfvf *rvu_get_pfvf(struct rvu *rvu, int pcifunc);
#endif /* RVU_H */
diff --git a/drivers/soc/marvell/octeontx2/rvu_struct.h b/drivers/soc/marvell/octeontx2/rvu_struct.h
index 1dc1518..77ac751 100644
--- a/drivers/soc/marvell/octeontx2/rvu_struct.h
+++ b/drivers/soc/marvell/octeontx2/rvu_struct.h
@@ -33,6 +33,24 @@ enum rvu_block_addr_e {
BLK_COUNT = 0xfULL,
};
+/*
+ * RVU Block Type Enumeration
+ */
+enum rvu_block_type_e {
+ BLKTYPE_RVUM = 0x0,
+ BLKTYPE_MSIX = 0x1,
+ BLKTYPE_LMT = 0x2,
+ BLKTYPE_NIX = 0x3,
+ BLKTYPE_NPA = 0x4,
+ BLKTYPE_NPC = 0x5,
+ BLKTYPE_SSO = 0x6,
+ BLKTYPE_SSOW = 0x7,
+ BLKTYPE_TIM = 0x8,
+ BLKTYPE_CPT = 0x9,
+ BLKTYPE_NDC = 0xa,
+ BLKTYPE_MAX = 0xa,
+};
+
/* RVU Admin function Interrupt Vector Enumeration */
enum rvu_af_int_vec_e {
RVU_AF_INT_VEC_POISON = 0x0,
--
2.7.4
^ permalink raw reply related
* [PATCH v3 09/15] soc: octeontx2: Configure block LF's MSIX vector offset
From: sunil.kovvuri @ 2018-09-04 16:28 UTC (permalink / raw)
To: linux-kernel, arnd, olof
Cc: linux-arm-kernel, linux-soc, andrew, davem, netdev, Sunil Goutham
In-Reply-To: <1536078525-31534-1-git-send-email-sunil.kovvuri@gmail.com>
From: Sunil Goutham <sgoutham@marvell.com>
Firmware configures a certain number of MSIX vectors to each of
enabled RVU PF/VF. When a block LF is attached to a PF/VF, number
of MSIX vectors needed by that LF are set aside (out of PF/VF's
total MSIX vectors) and LF's msix_offset is configured in HW.
Also added support for a RVU PF/VF to retrieve that block LF's
MSIX vector offset information from AF via mbox.
Signed-off-by: Sunil Goutham <sgoutham@marvell.com>
---
drivers/soc/marvell/octeontx2/mbox.h | 18 ++
drivers/soc/marvell/octeontx2/rvu.c | 333 ++++++++++++++++++++++++++++-
drivers/soc/marvell/octeontx2/rvu.h | 7 +
drivers/soc/marvell/octeontx2/rvu_struct.h | 2 +
4 files changed, 357 insertions(+), 3 deletions(-)
diff --git a/drivers/soc/marvell/octeontx2/mbox.h b/drivers/soc/marvell/octeontx2/mbox.h
index 7280d49..bedf0ee 100644
--- a/drivers/soc/marvell/octeontx2/mbox.h
+++ b/drivers/soc/marvell/octeontx2/mbox.h
@@ -122,6 +122,7 @@ static inline struct mbox_msghdr *otx2_mbox_alloc_msg(struct otx2_mbox *mbox,
M(READY, 0x001, msg_req, ready_msg_rsp) \
M(ATTACH_RESOURCES, 0x002, rsrc_attach, msg_rsp) \
M(DETACH_RESOURCES, 0x003, rsrc_detach, msg_rsp) \
+M(MSIX_OFFSET, 0x004, msg_req, msix_offset_rsp) \
/* CGX mbox IDs (range 0x200 - 0x3FF) */ \
/* NPA mbox IDs (range 0x400 - 0x5FF) */ \
/* SSO/SSOW mbox IDs (range 0x600 - 0x7FF) */ \
@@ -190,4 +191,21 @@ struct rsrc_detach {
u8 cptlfs:1;
};
+#define MSIX_VECTOR_INVALID 0xFFFF
+#define MAX_RVU_BLKLF_CNT 256
+
+struct msix_offset_rsp {
+ struct mbox_msghdr hdr;
+ u16 npa_msixoff;
+ u16 nix_msixoff;
+ u8 sso;
+ u8 ssow;
+ u8 timlfs;
+ u8 cptlfs;
+ u16 sso_msixoff[MAX_RVU_BLKLF_CNT];
+ u16 ssow_msixoff[MAX_RVU_BLKLF_CNT];
+ u16 timlf_msixoff[MAX_RVU_BLKLF_CNT];
+ u16 cptlf_msixoff[MAX_RVU_BLKLF_CNT];
+};
+
#endif /* MBOX_H */
diff --git a/drivers/soc/marvell/octeontx2/rvu.c b/drivers/soc/marvell/octeontx2/rvu.c
index 39dc45d..8ac3524 100644
--- a/drivers/soc/marvell/octeontx2/rvu.c
+++ b/drivers/soc/marvell/octeontx2/rvu.c
@@ -24,6 +24,11 @@
static int rvu_get_hwvf(struct rvu *rvu, int pcifunc);
+static void rvu_set_msix_offset(struct rvu *rvu, struct rvu_pfvf *pfvf,
+ struct rvu_block *block, int lf);
+static void rvu_clear_msix_offset(struct rvu *rvu, struct rvu_pfvf *pfvf,
+ struct rvu_block *block, int lf);
+
/* Supported devices */
static const struct pci_device_id rvu_id_table[] = {
{ PCI_DEVICE(PCI_VENDOR_ID_CAVIUM, PCI_DEVID_OCTEONTX2_RVU_AF) },
@@ -75,6 +80,45 @@ int rvu_alloc_rsrc(struct rsrc_bmap *rsrc)
return id;
}
+static int rvu_alloc_rsrc_contig(struct rsrc_bmap *rsrc, int nrsrc)
+{
+ int start;
+
+ if (!rsrc->bmap)
+ return -EINVAL;
+
+ start = bitmap_find_next_zero_area(rsrc->bmap, rsrc->max, 0, nrsrc, 0);
+ if (start >= rsrc->max)
+ return -ENOSPC;
+
+ bitmap_set(rsrc->bmap, start, nrsrc);
+ return start;
+}
+
+static void rvu_free_rsrc_contig(struct rsrc_bmap *rsrc, int nrsrc, int start)
+{
+ if (!rsrc->bmap)
+ return;
+ if (start >= rsrc->max)
+ return;
+
+ bitmap_clear(rsrc->bmap, start, nrsrc);
+}
+
+static bool rvu_rsrc_check_contig(struct rsrc_bmap *rsrc, int nrsrc)
+{
+ int start;
+
+ if (!rsrc->bmap)
+ return false;
+
+ start = bitmap_find_next_zero_area(rsrc->bmap, rsrc->max, 0, nrsrc, 0);
+ if (start >= rsrc->max)
+ return false;
+
+ return true;
+}
+
void rvu_free_rsrc(struct rsrc_bmap *rsrc, int id)
{
if (!rsrc->bmap)
@@ -103,6 +147,26 @@ int rvu_alloc_bitmap(struct rsrc_bmap *rsrc)
return 0;
}
+/* Get block LF's HW index from a PF_FUNC's block slot number */
+int rvu_get_lf(struct rvu *rvu, struct rvu_block *block, u16 pcifunc, u16 slot)
+{
+ int lf;
+ u16 match = 0;
+
+ spin_lock(&rvu->rsrc_lock);
+ for (lf = 0; lf < block->lf.max; lf++) {
+ if (block->fn_map[lf] == pcifunc) {
+ if (slot == match) {
+ spin_unlock(&rvu->rsrc_lock);
+ return lf;
+ }
+ match++;
+ }
+ }
+ spin_unlock(&rvu->rsrc_lock);
+ return -ENODEV;
+}
+
/* Convert BLOCK_TYPE_E to a BLOCK_ADDR_E.
* Some silicon variants of OcteonTX2 supports
* multiple blocks of same type.
@@ -237,6 +301,16 @@ inline int rvu_get_pf(u16 pcifunc)
return (pcifunc >> RVU_PFVF_PF_SHIFT) & RVU_PFVF_PF_MASK;
}
+void rvu_get_pf_numvfs(struct rvu *rvu, int pf, int *numvfs, int *hwvf)
+{
+ u64 cfg;
+
+ /* Get numVFs attached to this PF and first HWVF */
+ cfg = rvu_read64(rvu, BLKADDR_RVUM, RVU_PRIV_PFX_CFG(pf));
+ *numvfs = (cfg >> 12) & 0xFF;
+ *hwvf = cfg & 0xFFF;
+}
+
static int rvu_get_hwvf(struct rvu *rvu, int pcifunc)
{
int pf, func;
@@ -331,20 +405,150 @@ static void rvu_scan_block(struct rvu *rvu, struct rvu_block *block)
pfvf = rvu_get_pfvf(rvu, (cfg >> 8) & 0xFFFF);
rvu_update_rsrc_map(rvu, pfvf, block,
(cfg >> 8) & 0xFFFF, lf, true);
+
+ /* Set start MSIX vector for this LF within this PF/VF */
+ rvu_set_msix_offset(rvu, pfvf, block, lf);
}
}
+static void rvu_check_min_msix_vec(struct rvu *rvu, int nvecs, int pf, int vf)
+{
+ int min_vecs;
+
+ if (!vf)
+ goto check_pf;
+
+ if (!nvecs) {
+ dev_warn(rvu->dev,
+ "PF%d:VF%d is configured with zero msix vectors, %d\n",
+ pf, vf - 1, nvecs);
+ }
+ return;
+
+check_pf:
+ if (pf == 0)
+ min_vecs = RVU_AF_INT_VEC_CNT + RVU_PF_INT_VEC_CNT;
+ else
+ min_vecs = RVU_PF_INT_VEC_CNT;
+
+ if (!(nvecs < min_vecs))
+ return;
+ dev_warn(rvu->dev,
+ "PF%d is configured with too few vectors, %d, min is %d\n",
+ pf, nvecs, min_vecs);
+}
+
+static int rvu_setup_msix_resources(struct rvu *rvu)
+{
+ struct rvu_hwinfo *hw = rvu->hw;
+ int pf, vf, numvfs, hwvf, err;
+ struct rvu_pfvf *pfvf;
+ int nvecs, offset;
+ u64 cfg;
+
+ for (pf = 0; pf < hw->total_pfs; pf++) {
+ cfg = rvu_read64(rvu, BLKADDR_RVUM, RVU_PRIV_PFX_CFG(pf));
+ /* If PF is not enabled, nothing to do */
+ if (!((cfg >> 20) & 0x01))
+ continue;
+
+ rvu_get_pf_numvfs(rvu, pf, &numvfs, &hwvf);
+
+ pfvf = &rvu->pf[pf];
+ /* Get num of MSIX vectors attached to this PF */
+ cfg = rvu_read64(rvu, BLKADDR_RVUM, RVU_PRIV_PFX_MSIX_CFG(pf));
+ pfvf->msix.max = ((cfg >> 32) & 0xFFF) + 1;
+ rvu_check_min_msix_vec(rvu, pfvf->msix.max, pf, 0);
+
+ /* Alloc msix bitmap for this PF */
+ err = rvu_alloc_bitmap(&pfvf->msix);
+ if (err)
+ return err;
+
+ /* Allocate memory for MSIX vector to RVU block LF mapping */
+ pfvf->msix_lfmap = devm_kcalloc(rvu->dev, pfvf->msix.max,
+ sizeof(u16), GFP_KERNEL);
+ if (!pfvf->msix_lfmap)
+ return -ENOMEM;
+
+ /* For PF0 (AF) firmware will set msix vector offsets for
+ * AF, block AF and PF0_INT vectors, so jump to VFs.
+ */
+ if (!pf)
+ goto setup_vfmsix;
+
+ /* Set MSIX offset for PF's 'RVU_PF_INT_VEC' vectors.
+ * These are allocated on driver init and never freed,
+ * so no need to set 'msix_lfmap' for these.
+ */
+ cfg = rvu_read64(rvu, BLKADDR_RVUM, RVU_PRIV_PFX_INT_CFG(pf));
+ nvecs = (cfg >> 12) & 0xFF;
+ cfg &= ~0x7FFULL;
+ offset = rvu_alloc_rsrc_contig(&pfvf->msix, nvecs);
+ rvu_write64(rvu, BLKADDR_RVUM,
+ RVU_PRIV_PFX_INT_CFG(pf), cfg | offset);
+setup_vfmsix:
+ /* Alloc msix bitmap for VFs */
+ for (vf = 0; vf < numvfs; vf++) {
+ pfvf = &rvu->hwvf[hwvf + vf];
+ /* Get num of MSIX vectors attached to this VF */
+ cfg = rvu_read64(rvu, BLKADDR_RVUM,
+ RVU_PRIV_PFX_MSIX_CFG(pf));
+ pfvf->msix.max = (cfg & 0xFFF) + 1;
+ rvu_check_min_msix_vec(rvu, pfvf->msix.max, pf, vf + 1);
+
+ /* Alloc msix bitmap for this VF */
+ err = rvu_alloc_bitmap(&pfvf->msix);
+ if (err)
+ return err;
+
+ pfvf->msix_lfmap =
+ devm_kcalloc(rvu->dev, pfvf->msix.max,
+ sizeof(u16), GFP_KERNEL);
+ if (!pfvf->msix_lfmap)
+ return -ENOMEM;
+
+ /* Set MSIX offset for HWVF's 'RVU_VF_INT_VEC' vectors.
+ * These are allocated on driver init and never freed,
+ * so no need to set 'msix_lfmap' for these.
+ */
+ cfg = rvu_read64(rvu, BLKADDR_RVUM,
+ RVU_PRIV_HWVFX_INT_CFG(hwvf + vf));
+ nvecs = (cfg >> 12) & 0xFF;
+ cfg &= ~0x7FFULL;
+ offset = rvu_alloc_rsrc_contig(&pfvf->msix, nvecs);
+ rvu_write64(rvu, BLKADDR_RVUM,
+ RVU_PRIV_HWVFX_INT_CFG(hwvf + vf),
+ cfg | offset);
+ }
+ }
+
+ return 0;
+}
+
static void rvu_free_hw_resources(struct rvu *rvu)
{
struct rvu_hwinfo *hw = rvu->hw;
struct rvu_block *block;
+ struct rvu_pfvf *pfvf;
int id;
- /* Free all bitmaps */
+ /* Free block LF bitmaps */
for (id = 0; id < BLK_COUNT; id++) {
block = &hw->block[id];
kfree(block->lf.bmap);
}
+
+ /* Free MSIX bitmaps */
+ for (id = 0; id < hw->total_pfs; id++) {
+ pfvf = &rvu->pf[id];
+ kfree(pfvf->msix.bmap);
+ }
+
+ for (id = 0; id < hw->total_vfs; id++) {
+ pfvf = &rvu->hwvf[id];
+ kfree(pfvf->msix.bmap);
+ }
}
static int rvu_setup_hw_resources(struct rvu *rvu)
@@ -500,6 +704,12 @@ static int rvu_setup_hw_resources(struct rvu *rvu)
if (!rvu->hwvf)
return -ENOMEM;
+ spin_lock_init(&rvu->rsrc_lock);
+
+ err = rvu_setup_msix_resources(rvu);
+ if (err)
+ return err;
+
for (blkid = 0; blkid < BLK_COUNT; blkid++) {
block = &hw->block[blkid];
if (!block->lf.bmap)
@@ -517,8 +727,6 @@ static int rvu_setup_hw_resources(struct rvu *rvu)
rvu_scan_block(rvu, block);
}
- spin_lock_init(&rvu->rsrc_lock);
-
return 0;
}
@@ -604,6 +812,9 @@ static void rvu_detach_block(struct rvu *rvu, int pcifunc, int blktype)
/* Free the resource */
rvu_free_rsrc(&block->lf, lf);
+
+ /* Clear MSIX vector offset for this LF */
+ rvu_clear_msix_offset(rvu, pfvf, block, lf);
}
}
@@ -697,6 +908,9 @@ static void rvu_attach_block(struct rvu *rvu, int pcifunc,
(lf << block->lfshift), cfg);
rvu_update_rsrc_map(rvu, pfvf, block,
pcifunc, lf, true);
+
+ /* Set start MSIX vector for this LF within this PF/VF */
+ rvu_set_msix_offset(rvu, pfvf, block, lf);
}
}
@@ -872,6 +1086,119 @@ static int rvu_mbox_handler_ATTACH_RESOURCES(struct rvu *rvu,
return err;
}
+static u16 rvu_get_msix_offset(struct rvu *rvu, struct rvu_pfvf *pfvf,
+ int blkaddr, int lf)
+{
+ u16 vec;
+
+ if (lf < 0)
+ return MSIX_VECTOR_INVALID;
+
+ for (vec = 0; vec < pfvf->msix.max; vec++) {
+ if (pfvf->msix_lfmap[vec] == MSIX_BLKLF(blkaddr, lf))
+ return vec;
+ }
+ return MSIX_VECTOR_INVALID;
+}
+
+static void rvu_set_msix_offset(struct rvu *rvu, struct rvu_pfvf *pfvf,
+ struct rvu_block *block, int lf)
+{
+ u16 nvecs, vec, offset;
+ u64 cfg;
+
+ cfg = rvu_read64(rvu, block->addr, block->msixcfg_reg |
+ (lf << block->lfshift));
+ nvecs = (cfg >> 12) & 0xFF;
+
+ /* Check and alloc MSIX vectors, must be contiguous */
+ if (!rvu_rsrc_check_contig(&pfvf->msix, nvecs))
+ return;
+
+ offset = rvu_alloc_rsrc_contig(&pfvf->msix, nvecs);
+
+ /* Config MSIX offset in LF */
+ rvu_write64(rvu, block->addr, block->msixcfg_reg |
+ (lf << block->lfshift), (cfg & ~0x7FFULL) | offset);
+
+ /* Update the bitmap as well */
+ for (vec = 0; vec < nvecs; vec++)
+ pfvf->msix_lfmap[offset + vec] = MSIX_BLKLF(block->addr, lf);
+}
+
+static void rvu_clear_msix_offset(struct rvu *rvu, struct rvu_pfvf *pfvf,
+ struct rvu_block *block, int lf)
+{
+ u16 nvecs, vec, offset;
+ u64 cfg;
+
+ cfg = rvu_read64(rvu, block->addr, block->msixcfg_reg |
+ (lf << block->lfshift));
+ nvecs = (cfg >> 12) & 0xFF;
+
+ /* Clear MSIX offset in LF */
+ rvu_write64(rvu, block->addr, block->msixcfg_reg |
+ (lf << block->lfshift), cfg & ~0x7FFULL);
+
+ offset = rvu_get_msix_offset(rvu, pfvf, block->addr, lf);
+
+ /* Update the mapping */
+ for (vec = 0; vec < nvecs; vec++)
+ pfvf->msix_lfmap[offset + vec] = 0;
+
+ /* Free the same in MSIX bitmap */
+ rvu_free_rsrc_contig(&pfvf->msix, nvecs, offset);
+}
+
+static int rvu_mbox_handler_MSIX_OFFSET(struct rvu *rvu, struct msg_req *req,
+ struct msix_offset_rsp *rsp)
+{
+ struct rvu_hwinfo *hw = rvu->hw;
+ u16 pcifunc = req->hdr.pcifunc;
+ struct rvu_pfvf *pfvf;
+ int lf, slot;
+
+ pfvf = rvu_get_pfvf(rvu, pcifunc);
+ if (!pfvf->msix.bmap)
+ return 0;
+
+ /* Set MSIX offsets for each block's LFs attached to this PF/VF */
+ lf = rvu_get_lf(rvu, &hw->block[BLKADDR_NPA], pcifunc, 0);
+ rsp->npa_msixoff = rvu_get_msix_offset(rvu, pfvf, BLKADDR_NPA, lf);
+
+ lf = rvu_get_lf(rvu, &hw->block[BLKADDR_NIX0], pcifunc, 0);
+ rsp->nix_msixoff = rvu_get_msix_offset(rvu, pfvf, BLKADDR_NIX0, lf);
+
+ rsp->sso = pfvf->sso;
+ for (slot = 0; slot < rsp->sso; slot++) {
+ lf = rvu_get_lf(rvu, &hw->block[BLKADDR_SSO], pcifunc, slot);
+ rsp->sso_msixoff[slot] =
+ rvu_get_msix_offset(rvu, pfvf, BLKADDR_SSO, lf);
+ }
+
+ rsp->ssow = pfvf->ssow;
+ for (slot = 0; slot < rsp->ssow; slot++) {
+ lf = rvu_get_lf(rvu, &hw->block[BLKADDR_SSOW], pcifunc, slot);
+ rsp->ssow_msixoff[slot] =
+ rvu_get_msix_offset(rvu, pfvf, BLKADDR_SSOW, lf);
+ }
+
+ rsp->timlfs = pfvf->timlfs;
+ for (slot = 0; slot < rsp->timlfs; slot++) {
+ lf = rvu_get_lf(rvu, &hw->block[BLKADDR_TIM], pcifunc, slot);
+ rsp->timlf_msixoff[slot] =
+ rvu_get_msix_offset(rvu, pfvf, BLKADDR_TIM, lf);
+ }
+
+ rsp->cptlfs = pfvf->cptlfs;
+ for (slot = 0; slot < rsp->cptlfs; slot++) {
+ lf = rvu_get_lf(rvu, &hw->block[BLKADDR_CPT0], pcifunc, slot);
+ rsp->cptlf_msixoff[slot] =
+ rvu_get_msix_offset(rvu, pfvf, BLKADDR_CPT0, lf);
+ }
+ return 0;
+}
+
static int rvu_process_mbox_msg(struct rvu *rvu, int devid,
struct mbox_msghdr *req)
{
diff --git a/drivers/soc/marvell/octeontx2/rvu.h b/drivers/soc/marvell/octeontx2/rvu.h
index 0f76704..7435e83 100644
--- a/drivers/soc/marvell/octeontx2/rvu.h
+++ b/drivers/soc/marvell/octeontx2/rvu.h
@@ -65,6 +65,11 @@ struct rvu_pfvf {
u16 ssow;
u16 cptlfs;
u16 timlfs;
+
+ /* Block LF's MSIX vector info */
+ struct rsrc_bmap msix; /* Bitmap for MSIX vector alloc */
+#define MSIX_BLKLF(blkaddr, lf) (((blkaddr) << 8) | ((lf) & 0xFF))
+ u16 *msix_lfmap; /* Vector to block LF mapping */
};
struct rvu_hwinfo {
@@ -126,7 +131,9 @@ void rvu_free_rsrc(struct rsrc_bmap *rsrc, int id);
int rvu_rsrc_free_count(struct rsrc_bmap *rsrc);
int rvu_get_pf(u16 pcifunc);
struct rvu_pfvf *rvu_get_pfvf(struct rvu *rvu, int pcifunc);
+void rvu_get_pf_numvfs(struct rvu *rvu, int pf, int *numvfs, int *hwvf);
bool is_block_implemented(struct rvu_hwinfo *hw, int blkaddr);
+int rvu_get_lf(struct rvu *rvu, struct rvu_block *block, u16 pcifunc, u16 slot);
int rvu_get_blkaddr(struct rvu *rvu, int blktype, u16 pcifunc);
int rvu_poll_reg(struct rvu *rvu, u64 block, u64 offset, u64 mask, bool zero);
diff --git a/drivers/soc/marvell/octeontx2/rvu_struct.h b/drivers/soc/marvell/octeontx2/rvu_struct.h
index 77ac751..f61c862 100644
--- a/drivers/soc/marvell/octeontx2/rvu_struct.h
+++ b/drivers/soc/marvell/octeontx2/rvu_struct.h
@@ -58,6 +58,7 @@ enum rvu_af_int_vec_e {
RVU_AF_INT_VEC_PFME = 0x2,
RVU_AF_INT_VEC_GEN = 0x3,
RVU_AF_INT_VEC_MBOX = 0x4,
+ RVU_AF_INT_VEC_CNT = 0x5,
};
/**
@@ -71,6 +72,7 @@ enum rvu_pf_int_vec_e {
RVU_PF_INT_VEC_VFPF_MBOX0 = 0x4,
RVU_PF_INT_VEC_VFPF_MBOX1 = 0x5,
RVU_PF_INT_VEC_AFPF_MBOX = 0x6,
+ RVU_PF_INT_VEC_CNT = 0x7,
};
#endif /* RVU_STRUCT_H */
--
2.7.4
^ permalink raw reply related
* [PATCH v3 10/15] soc: octeontx2: Reconfig MSIX base with IOVA
From: sunil.kovvuri @ 2018-09-04 16:28 UTC (permalink / raw)
To: linux-kernel, arnd, olof
Cc: linux-arm-kernel, linux-soc, andrew, davem, netdev,
Geetha sowjanya, Sunil Goutham
In-Reply-To: <1536078525-31534-1-git-send-email-sunil.kovvuri@gmail.com>
From: Geetha sowjanya <gakula@marvell.com>
HW interprets RVU_AF_MSIXTR_BASE address as an IOVA, hence
create a IOMMU mapping for the physcial address configured by
firmware and reconfig RVU_AF_MSIXTR_BASE with IOVA.
Signed-off-by: Geetha sowjanya <gakula@marvell.com>
Signed-off-by: Sunil Goutham <sgoutham@marvell.com>
---
drivers/soc/marvell/octeontx2/rvu.c | 33 ++++++++++++++++++++++++++++++---
drivers/soc/marvell/octeontx2/rvu.h | 1 +
2 files changed, 31 insertions(+), 3 deletions(-)
diff --git a/drivers/soc/marvell/octeontx2/rvu.c b/drivers/soc/marvell/octeontx2/rvu.c
index 8ac3524..40684c9 100644
--- a/drivers/soc/marvell/octeontx2/rvu.c
+++ b/drivers/soc/marvell/octeontx2/rvu.c
@@ -442,9 +442,10 @@ static int rvu_setup_msix_resources(struct rvu *rvu)
{
struct rvu_hwinfo *hw = rvu->hw;
int pf, vf, numvfs, hwvf, err;
+ int nvecs, offset, max_msix;
struct rvu_pfvf *pfvf;
- int nvecs, offset;
- u64 cfg;
+ u64 cfg, phy_addr;
+ dma_addr_t iova;
for (pf = 0; pf < hw->total_pfs; pf++) {
cfg = rvu_read64(rvu, BLKADDR_RVUM, RVU_PRIV_PFX_CFG(pf));
@@ -523,6 +524,22 @@ static int rvu_setup_msix_resources(struct rvu *rvu)
}
}
+ /* HW interprets RVU_AF_MSIXTR_BASE address as an IOVA, hence
+ * create a IOMMU mapping for the physcial address configured by
+ * firmware and reconfig RVU_AF_MSIXTR_BASE with IOVA.
+ */
+ cfg = rvu_read64(rvu, BLKADDR_RVUM, RVU_PRIV_CONST);
+ max_msix = cfg & 0xFFFFF;
+ phy_addr = rvu_read64(rvu, BLKADDR_RVUM, RVU_AF_MSIXTR_BASE);
+ iova = dma_map_single(rvu->dev, (void *)phy_addr,
+ max_msix * PCI_MSIX_ENTRY_SIZE,
+ DMA_BIDIRECTIONAL);
+ if (dma_mapping_error(rvu->dev, iova))
+ return -ENOMEM;
+
+ rvu_write64(rvu, BLKADDR_RVUM, RVU_AF_MSIXTR_BASE, (u64)iova);
+ rvu->msix_base_iova = iova;
+
return 0;
}
@@ -531,7 +548,8 @@ static void rvu_free_hw_resources(struct rvu *rvu)
struct rvu_hwinfo *hw = rvu->hw;
struct rvu_block *block;
struct rvu_pfvf *pfvf;
- int id;
+ int id, max_msix;
+ u64 cfg;
/* Free block LF bitmaps */
for (id = 0; id < BLK_COUNT; id++) {
@@ -549,6 +567,15 @@ static void rvu_free_hw_resources(struct rvu *rvu)
pfvf = &rvu->hwvf[id];
kfree(pfvf->msix.bmap);
}
+
+ /* Unmap MSIX vector base IOVA mapping */
+ if (!rvu->msix_base_iova)
+ return;
+ cfg = rvu_read64(rvu, BLKADDR_RVUM, RVU_PRIV_CONST);
+ max_msix = cfg & 0xFFFFF;
+ dma_unmap_single(rvu->dev, rvu->msix_base_iova,
+ max_msix * PCI_MSIX_ENTRY_SIZE,
+ DMA_BIDIRECTIONAL);
}
static int rvu_setup_hw_resources(struct rvu *rvu)
diff --git a/drivers/soc/marvell/octeontx2/rvu.h b/drivers/soc/marvell/octeontx2/rvu.h
index 7435e83..92c2022 100644
--- a/drivers/soc/marvell/octeontx2/rvu.h
+++ b/drivers/soc/marvell/octeontx2/rvu.h
@@ -99,6 +99,7 @@ struct rvu {
u16 num_vec;
char *irq_name;
bool *irq_allocated;
+ dma_addr_t msix_base_iova;
};
static inline void rvu_write64(struct rvu *rvu, u64 block, u64 offset, u64 val)
--
2.7.4
^ permalink raw reply related
* [PATCH v3 11/15] soc: octeontx2: Add Marvell OcteonTX2 CGX driver
From: sunil.kovvuri @ 2018-09-04 16:28 UTC (permalink / raw)
To: linux-kernel, arnd, olof
Cc: linux-arm-kernel, linux-soc, andrew, davem, netdev, Sunil Goutham
In-Reply-To: <1536078525-31534-1-git-send-email-sunil.kovvuri@gmail.com>
From: Sunil Goutham <sgoutham@marvell.com>
This patch adds basic template for Marvell OcteonTX2's
CGX ethernet interface driver. Just the probe.
RVU AF driver will use APIs exported by this driver
for various things like PF to physical interface mapping,
loopback mode, interface stats etc. Hence marged both
drivers into a single module.
Signed-off-by: Sunil Goutham <sgoutham@marvell.com>
---
drivers/soc/marvell/Kconfig | 3 +-
drivers/soc/marvell/octeontx2/Makefile | 2 +-
drivers/soc/marvell/octeontx2/cgx.c | 102 +++++++++++++++++++++++++++++++++
drivers/soc/marvell/octeontx2/cgx.h | 22 +++++++
drivers/soc/marvell/octeontx2/rvu.c | 14 ++++-
5 files changed, 140 insertions(+), 3 deletions(-)
create mode 100644 drivers/soc/marvell/octeontx2/cgx.c
create mode 100644 drivers/soc/marvell/octeontx2/cgx.h
diff --git a/drivers/soc/marvell/Kconfig b/drivers/soc/marvell/Kconfig
index 428d22e..8f36f3a 100644
--- a/drivers/soc/marvell/Kconfig
+++ b/drivers/soc/marvell/Kconfig
@@ -11,7 +11,8 @@ config OCTEONTX2_AF
tristate "OcteonTX2 RVU Admin Function driver"
select OCTEONTX2_MBOX
depends on ARM64 && PCI
- help
+ ---help---
This driver supports Marvell's OcteonTX2 Resource Virtualization
Unit's admin function manager which manages all RVU HW resources.
+
endmenu
diff --git a/drivers/soc/marvell/octeontx2/Makefile b/drivers/soc/marvell/octeontx2/Makefile
index ac17cb9..8646421 100644
--- a/drivers/soc/marvell/octeontx2/Makefile
+++ b/drivers/soc/marvell/octeontx2/Makefile
@@ -7,4 +7,4 @@ obj-$(CONFIG_OCTEONTX2_MBOX) += octeontx2_mbox.o
obj-$(CONFIG_OCTEONTX2_AF) += octeontx2_af.o
octeontx2_mbox-y := mbox.o
-octeontx2_af-y := rvu.o
+octeontx2_af-y := cgx.o rvu.o
diff --git a/drivers/soc/marvell/octeontx2/cgx.c b/drivers/soc/marvell/octeontx2/cgx.c
new file mode 100644
index 0000000..47aa4cb
--- /dev/null
+++ b/drivers/soc/marvell/octeontx2/cgx.c
@@ -0,0 +1,102 @@
+// SPDX-License-Identifier: GPL-2.0
+/* Marvell OcteonTx2 CGX driver
+ *
+ * Copyright (C) 2018 Marvell International Ltd.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+
+#include <linux/acpi.h>
+#include <linux/module.h>
+#include <linux/interrupt.h>
+#include <linux/pci.h>
+#include <linux/netdevice.h>
+#include <linux/etherdevice.h>
+#include <linux/phy.h>
+#include <linux/of.h>
+#include <linux/of_mdio.h>
+#include <linux/of_net.h>
+
+#include "cgx.h"
+
+#define DRV_NAME "octeontx2-cgx"
+#define DRV_STRING "Marvell OcteonTX2 CGX/MAC Driver"
+#define DRV_VERSION "1.0"
+
+struct cgx {
+ void __iomem *reg_base;
+ struct pci_dev *pdev;
+ u8 cgx_id;
+};
+
+/* Supported devices */
+static const struct pci_device_id cgx_id_table[] = {
+ { PCI_DEVICE(PCI_VENDOR_ID_CAVIUM, PCI_DEVID_OCTEONTX2_CGX) },
+ { 0, } /* end of table */
+};
+
+MODULE_AUTHOR("Marvell International Ltd.");
+MODULE_DESCRIPTION(DRV_STRING);
+MODULE_LICENSE("GPL v2");
+MODULE_VERSION(DRV_VERSION);
+MODULE_DEVICE_TABLE(pci, cgx_id_table);
+
+static int cgx_probe(struct pci_dev *pdev, const struct pci_device_id *id)
+{
+ int err;
+ struct device *dev = &pdev->dev;
+ struct cgx *cgx;
+
+ cgx = devm_kzalloc(dev, sizeof(*cgx), GFP_KERNEL);
+ if (!cgx)
+ return -ENOMEM;
+ cgx->pdev = pdev;
+
+ pci_set_drvdata(pdev, cgx);
+
+ err = pci_enable_device(pdev);
+ if (err) {
+ dev_err(dev, "Failed to enable PCI device\n");
+ pci_set_drvdata(pdev, NULL);
+ return err;
+ }
+
+ err = pci_request_regions(pdev, DRV_NAME);
+ if (err) {
+ dev_err(dev, "PCI request regions failed 0x%x\n", err);
+ goto err_disable_device;
+ }
+
+ /* MAP configuration registers */
+ cgx->reg_base = pcim_iomap(pdev, PCI_CFG_REG_BAR_NUM, 0);
+ if (!cgx->reg_base) {
+ dev_err(dev, "CGX: Cannot map CSR memory space, aborting\n");
+ err = -ENOMEM;
+ goto err_release_regions;
+ }
+
+ return 0;
+
+err_release_regions:
+ pci_release_regions(pdev);
+err_disable_device:
+ pci_disable_device(pdev);
+ pci_set_drvdata(pdev, NULL);
+ return err;
+}
+
+static void cgx_remove(struct pci_dev *pdev)
+{
+ pci_release_regions(pdev);
+ pci_disable_device(pdev);
+ pci_set_drvdata(pdev, NULL);
+}
+
+struct pci_driver cgx_driver = {
+ .name = DRV_NAME,
+ .id_table = cgx_id_table,
+ .probe = cgx_probe,
+ .remove = cgx_remove,
+};
diff --git a/drivers/soc/marvell/octeontx2/cgx.h b/drivers/soc/marvell/octeontx2/cgx.h
new file mode 100644
index 0000000..a7d4b39
--- /dev/null
+++ b/drivers/soc/marvell/octeontx2/cgx.h
@@ -0,0 +1,22 @@
+/* SPDX-License-Identifier: GPL-2.0
+ * Marvell OcteonTx2 CGX driver
+ *
+ * Copyright (C) 2018 Marvell International Ltd.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+
+#ifndef CGX_H
+#define CGX_H
+
+ /* PCI device IDs */
+#define PCI_DEVID_OCTEONTX2_CGX 0xA059
+
+/* PCI BAR nos */
+#define PCI_CFG_REG_BAR_NUM 0
+
+extern struct pci_driver cgx_driver;
+
+#endif /* CGX_H */
diff --git a/drivers/soc/marvell/octeontx2/rvu.c b/drivers/soc/marvell/octeontx2/rvu.c
index 40684c9..daa6fd3 100644
--- a/drivers/soc/marvell/octeontx2/rvu.c
+++ b/drivers/soc/marvell/octeontx2/rvu.c
@@ -15,6 +15,7 @@
#include <linux/pci.h>
#include <linux/sysfs.h>
+#include "cgx.h"
#include "rvu.h"
#include "rvu_reg.h"
@@ -1605,14 +1606,25 @@ static struct pci_driver rvu_driver = {
static int __init rvu_init_module(void)
{
+ int err;
+
pr_info("%s: %s\n", DRV_NAME, DRV_STRING);
- return pci_register_driver(&rvu_driver);
+ err = pci_register_driver(&cgx_driver);
+ if (err < 0)
+ return err;
+
+ err = pci_register_driver(&rvu_driver);
+ if (err < 0)
+ pci_unregister_driver(&cgx_driver);
+
+ return err;
}
static void __exit rvu_cleanup_module(void)
{
pci_unregister_driver(&rvu_driver);
+ pci_unregister_driver(&cgx_driver);
}
module_init(rvu_init_module);
--
2.7.4
^ permalink raw reply related
* [PATCH v3 12/15] soc: octeontx2: Set RVU PFs to CGX LMACs mapping
From: sunil.kovvuri @ 2018-09-04 16:28 UTC (permalink / raw)
To: linux-kernel, arnd, olof
Cc: linux-arm-kernel, linux-soc, andrew, davem, netdev, Linu Cherian,
Geetha sowjanya
In-Reply-To: <1536078525-31534-1-git-send-email-sunil.kovvuri@gmail.com>
From: Linu Cherian <lcherian@marvell.com>
Each of the enabled CGX LMAC is considered a physical
interface and RVU PFs are mapped to these. VFs of these
SRIOV PFs will be virtual interfaces and share CGX LMAC
along with PF.
This mapping info will be used later on for Rx/Tx pkt steering.
Signed-off-by: Linu Cherian <lcherian@marvell.com>
Signed-off-by: Geetha sowjanya <gakula@marvell.com>
---
drivers/soc/marvell/octeontx2/Makefile | 2 +-
drivers/soc/marvell/octeontx2/cgx.c | 59 ++++++++++++++++++++
drivers/soc/marvell/octeontx2/cgx.h | 15 ++++-
drivers/soc/marvell/octeontx2/rvu.c | 4 ++
drivers/soc/marvell/octeontx2/rvu.h | 12 ++++
drivers/soc/marvell/octeontx2/rvu_cgx.c | 97 +++++++++++++++++++++++++++++++++
6 files changed, 186 insertions(+), 3 deletions(-)
create mode 100644 drivers/soc/marvell/octeontx2/rvu_cgx.c
diff --git a/drivers/soc/marvell/octeontx2/Makefile b/drivers/soc/marvell/octeontx2/Makefile
index 8646421..eaac264 100644
--- a/drivers/soc/marvell/octeontx2/Makefile
+++ b/drivers/soc/marvell/octeontx2/Makefile
@@ -7,4 +7,4 @@ obj-$(CONFIG_OCTEONTX2_MBOX) += octeontx2_mbox.o
obj-$(CONFIG_OCTEONTX2_AF) += octeontx2_af.o
octeontx2_mbox-y := mbox.o
-octeontx2_af-y := cgx.o rvu.o
+octeontx2_af-y := cgx.o rvu.o rvu_cgx.o
diff --git a/drivers/soc/marvell/octeontx2/cgx.c b/drivers/soc/marvell/octeontx2/cgx.c
index 47aa4cb..c5e0ebb 100644
--- a/drivers/soc/marvell/octeontx2/cgx.c
+++ b/drivers/soc/marvell/octeontx2/cgx.c
@@ -29,8 +29,12 @@ struct cgx {
void __iomem *reg_base;
struct pci_dev *pdev;
u8 cgx_id;
+ u8 lmac_count;
+ struct list_head cgx_list;
};
+static LIST_HEAD(cgx_list);
+
/* Supported devices */
static const struct pci_device_id cgx_id_table[] = {
{ PCI_DEVICE(PCI_VENDOR_ID_CAVIUM, PCI_DEVID_OCTEONTX2_CGX) },
@@ -43,6 +47,53 @@ MODULE_LICENSE("GPL v2");
MODULE_VERSION(DRV_VERSION);
MODULE_DEVICE_TABLE(pci, cgx_id_table);
+static u64 cgx_read(struct cgx *cgx, u64 lmac, u64 offset)
+{
+ return readq(cgx->reg_base + (lmac << 18) + offset);
+}
+
+int cgx_get_cgx_cnt(void)
+{
+ struct cgx *cgx_dev;
+ int count = 0;
+
+ list_for_each_entry(cgx_dev, &cgx_list, cgx_list)
+ count++;
+
+ return count;
+}
+EXPORT_SYMBOL(cgx_get_cgx_cnt);
+
+int cgx_get_lmac_cnt(void *cgxd)
+{
+ struct cgx *cgx = cgxd;
+
+ if (!cgx)
+ return -ENODEV;
+
+ return cgx->lmac_count;
+}
+EXPORT_SYMBOL(cgx_get_lmac_cnt);
+
+void *cgx_get_pdata(int cgx_id)
+{
+ struct cgx *cgx_dev;
+
+ list_for_each_entry(cgx_dev, &cgx_list, cgx_list) {
+ if (cgx_dev->cgx_id == cgx_id)
+ return cgx_dev;
+ }
+ return NULL;
+}
+EXPORT_SYMBOL(cgx_get_pdata);
+
+static void cgx_lmac_init(struct cgx *cgx)
+{
+ cgx->lmac_count = cgx_read(cgx, 0, CGXX_CMRX_RX_LMACS) & 0x7;
+ if (cgx->lmac_count > MAX_LMAC_PER_CGX)
+ cgx->lmac_count = MAX_LMAC_PER_CGX;
+}
+
static int cgx_probe(struct pci_dev *pdev, const struct pci_device_id *id)
{
int err;
@@ -77,9 +128,14 @@ static int cgx_probe(struct pci_dev *pdev, const struct pci_device_id *id)
goto err_release_regions;
}
+ list_add(&cgx->cgx_list, &cgx_list);
+ cgx->cgx_id = cgx_get_cgx_cnt() - 1;
+ cgx_lmac_init(cgx);
+
return 0;
err_release_regions:
+ list_del(&cgx->cgx_list);
pci_release_regions(pdev);
err_disable_device:
pci_disable_device(pdev);
@@ -89,6 +145,9 @@ static int cgx_probe(struct pci_dev *pdev, const struct pci_device_id *id)
static void cgx_remove(struct pci_dev *pdev)
{
+ struct cgx *cgx = pci_get_drvdata(pdev);
+
+ list_del(&cgx->cgx_list);
pci_release_regions(pdev);
pci_disable_device(pdev);
pci_set_drvdata(pdev, NULL);
diff --git a/drivers/soc/marvell/octeontx2/cgx.h b/drivers/soc/marvell/octeontx2/cgx.h
index a7d4b39..acdc16e 100644
--- a/drivers/soc/marvell/octeontx2/cgx.h
+++ b/drivers/soc/marvell/octeontx2/cgx.h
@@ -12,11 +12,22 @@
#define CGX_H
/* PCI device IDs */
-#define PCI_DEVID_OCTEONTX2_CGX 0xA059
+#define PCI_DEVID_OCTEONTX2_CGX 0xA059
/* PCI BAR nos */
-#define PCI_CFG_REG_BAR_NUM 0
+#define PCI_CFG_REG_BAR_NUM 0
+
+#define MAX_CGX 3
+#define MAX_LMAC_PER_CGX 4
+#define CGX_OFFSET(x) ((x) * MAX_LMAC_PER_CGX)
+
+/* Registers */
+#define CGXX_CMRX_RX_ID_MAP 0x060
+#define CGXX_CMRX_RX_LMACS 0x128
extern struct pci_driver cgx_driver;
+int cgx_get_cgx_cnt(void);
+int cgx_get_lmac_cnt(void *cgxd);
+void *cgx_get_pdata(int cgx_id);
#endif /* CGX_H */
diff --git a/drivers/soc/marvell/octeontx2/rvu.c b/drivers/soc/marvell/octeontx2/rvu.c
index daa6fd3..faf7d0f 100644
--- a/drivers/soc/marvell/octeontx2/rvu.c
+++ b/drivers/soc/marvell/octeontx2/rvu.c
@@ -1558,6 +1558,10 @@ static int rvu_probe(struct pci_dev *pdev, const struct pci_device_id *id)
if (err)
goto err_hwsetup;
+ err = rvu_cgx_probe(rvu);
+ if (err)
+ goto err_mbox;
+
err = rvu_register_interrupts(rvu);
if (err)
goto err_mbox;
diff --git a/drivers/soc/marvell/octeontx2/rvu.h b/drivers/soc/marvell/octeontx2/rvu.h
index 92c2022..385f597 100644
--- a/drivers/soc/marvell/octeontx2/rvu.h
+++ b/drivers/soc/marvell/octeontx2/rvu.h
@@ -100,6 +100,16 @@ struct rvu {
char *irq_name;
bool *irq_allocated;
dma_addr_t msix_base_iova;
+
+ /* CGX */
+#define PF_CGXMAP_BASE 1 /* PF 0 is reserved for RVU PF */
+ u8 cgx_mapped_pfs;
+ u8 cgx_cnt; /* available cgx ports */
+ u8 *pf2cgxlmac_map; /* pf to cgx_lmac map */
+ u16 *cgxlmac2pf_map; /* bitmap of mapped pfs for
+ * every cgx lmac port
+ */
+ void **cgx_idmap; /* cgx id to cgx data map table */
};
static inline void rvu_write64(struct rvu *rvu, u64 block, u64 offset, u64 val)
@@ -138,4 +148,6 @@ int rvu_get_lf(struct rvu *rvu, struct rvu_block *block, u16 pcifunc, u16 slot);
int rvu_get_blkaddr(struct rvu *rvu, int blktype, u16 pcifunc);
int rvu_poll_reg(struct rvu *rvu, u64 block, u64 offset, u64 mask, bool zero);
+/* CGX APIs */
+int rvu_cgx_probe(struct rvu *rvu);
#endif /* RVU_H */
diff --git a/drivers/soc/marvell/octeontx2/rvu_cgx.c b/drivers/soc/marvell/octeontx2/rvu_cgx.c
new file mode 100644
index 0000000..bf81507
--- /dev/null
+++ b/drivers/soc/marvell/octeontx2/rvu_cgx.c
@@ -0,0 +1,97 @@
+// SPDX-License-Identifier: GPL-2.0
+/* Marvell OcteonTx2 RVU Admin Function driver
+ *
+ * Copyright (C) 2018 Marvell International Ltd.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+
+#include <linux/types.h>
+#include <linux/module.h>
+#include <linux/pci.h>
+
+#include "rvu.h"
+#include "cgx.h"
+
+static inline u8 cgxlmac_id_to_bmap(u8 cgx_id, u8 lmac_id)
+{
+ return ((cgx_id & 0xF) << 4) | (lmac_id & 0xF);
+}
+
+static void *rvu_cgx_pdata(u8 cgx_id, struct rvu *rvu)
+{
+ if (cgx_id >= rvu->cgx_cnt)
+ return NULL;
+
+ return rvu->cgx_idmap[cgx_id];
+}
+
+static int rvu_map_cgx_lmac_pf(struct rvu *rvu)
+{
+ int cgx_cnt = rvu->cgx_cnt;
+ int cgx, lmac_cnt, lmac;
+ int pf = PF_CGXMAP_BASE;
+ int size;
+
+ if (!cgx_cnt)
+ return 0;
+
+ if (cgx_cnt > 0xF || MAX_LMAC_PER_CGX > 0xF)
+ return -EINVAL;
+
+ /* Alloc map table
+ * An additional entry is required since PF id starts from 1 and
+ * hence entry at offset 0 is invalid.
+ */
+ size = (cgx_cnt * MAX_LMAC_PER_CGX + 1) * sizeof(u8);
+ rvu->pf2cgxlmac_map = devm_kzalloc(rvu->dev, size, GFP_KERNEL);
+ if (!rvu->pf2cgxlmac_map)
+ return -ENOMEM;
+
+ /* Initialize offset 0 with an invalid cgx and lmac id */
+ rvu->pf2cgxlmac_map[0] = 0xFF;
+
+ /* Reverse map table */
+ rvu->cgxlmac2pf_map = devm_kzalloc(rvu->dev,
+ cgx_cnt * MAX_LMAC_PER_CGX * sizeof(u16),
+ GFP_KERNEL);
+ if (!rvu->cgxlmac2pf_map)
+ return -ENOMEM;
+
+ rvu->cgx_mapped_pfs = 0;
+ for (cgx = 0; cgx < cgx_cnt; cgx++) {
+ lmac_cnt = cgx_get_lmac_cnt(rvu_cgx_pdata(cgx, rvu));
+ for (lmac = 0; lmac < lmac_cnt; lmac++, pf++) {
+ rvu->pf2cgxlmac_map[pf] = cgxlmac_id_to_bmap(cgx, lmac);
+ rvu->cgxlmac2pf_map[CGX_OFFSET(cgx) + lmac] = 1 << pf;
+ rvu->cgx_mapped_pfs++;
+ }
+ }
+ return 0;
+}
+
+int rvu_cgx_probe(struct rvu *rvu)
+{
+ int i;
+
+ /* find available cgx ports */
+ rvu->cgx_cnt = cgx_get_cgx_cnt();
+ if (!rvu->cgx_cnt) {
+ dev_info(rvu->dev, "No CGX devices found!\n");
+ return -ENODEV;
+ }
+
+ rvu->cgx_idmap = devm_kzalloc(rvu->dev, rvu->cgx_cnt * sizeof(void *),
+ GFP_KERNEL);
+ if (!rvu->cgx_idmap)
+ return -ENOMEM;
+
+ /* Initialize the cgxdata table */
+ for (i = 0; i < rvu->cgx_cnt; i++)
+ rvu->cgx_idmap[i] = cgx_get_pdata(i);
+
+ /* Map CGX LMAC interfaces to RVU PFs */
+ return rvu_map_cgx_lmac_pf(rvu);
+}
--
2.7.4
^ permalink raw reply related
* [PATCH v3 13/15] soc: octeontx2: Add support for CGX link management
From: sunil.kovvuri @ 2018-09-04 16:28 UTC (permalink / raw)
To: linux-kernel, arnd, olof
Cc: linux-arm-kernel, linux-soc, andrew, davem, netdev, Linu Cherian,
Nithya Mani
In-Reply-To: <1536078525-31534-1-git-send-email-sunil.kovvuri@gmail.com>
From: Linu Cherian <lcherian@marvell.com>
CGX LMAC initialization, link status polling etc is done
by low level secure firmware. For link management this patch
adds a interface or communication mechanism between firmware
and this kernel CGX driver.
- Firmware interface specification is defined in cgx_fw_if.h.
- Support to send/receive commands/events to/form firmware.
- events/commands implemented
* link up
* link down
* reading firmware version
Signed-off-by: Linu Cherian <lcherian@marvell.com>
Signed-off-by: Nithya Mani <nmani@marvell.com>
---
drivers/soc/marvell/octeontx2/cgx.c | 364 +++++++++++++++++++++++++++++-
drivers/soc/marvell/octeontx2/cgx.h | 32 +++
drivers/soc/marvell/octeontx2/cgx_fw_if.h | 225 ++++++++++++++++++
3 files changed, 617 insertions(+), 4 deletions(-)
create mode 100644 drivers/soc/marvell/octeontx2/cgx_fw_if.h
diff --git a/drivers/soc/marvell/octeontx2/cgx.c b/drivers/soc/marvell/octeontx2/cgx.c
index c5e0ebb..26af8fa 100644
--- a/drivers/soc/marvell/octeontx2/cgx.c
+++ b/drivers/soc/marvell/octeontx2/cgx.c
@@ -25,16 +25,43 @@
#define DRV_STRING "Marvell OcteonTX2 CGX/MAC Driver"
#define DRV_VERSION "1.0"
+/**
+ * struct lmac
+ * @wq_cmd_cmplt: waitq to keep the process blocked until cmd completion
+ * @cmd_lock: Lock to serialize the command interface
+ * @resp: command response
+ * @event_cb: callback for linkchange events
+ * @cmd_pend: flag set before new command is started
+ * flag cleared after command response is received
+ * @cgx: parent cgx port
+ * @lmac_id: lmac port id
+ * @name: lmac port name
+ */
+struct lmac {
+ wait_queue_head_t wq_cmd_cmplt;
+ struct mutex cmd_lock;
+ struct cgx_evt_sts resp;
+ struct cgx_event_cb event_cb;
+ bool cmd_pend;
+ struct cgx *cgx;
+ u8 lmac_id;
+ char *name;
+};
+
struct cgx {
void __iomem *reg_base;
struct pci_dev *pdev;
u8 cgx_id;
u8 lmac_count;
+ struct lmac *lmac_idmap[MAX_LMAC_PER_CGX];
struct list_head cgx_list;
};
static LIST_HEAD(cgx_list);
+/* CGX PHY management internal APIs */
+static int cgx_fwi_link_change(struct cgx *cgx, int lmac_id, bool en);
+
/* Supported devices */
static const struct pci_device_id cgx_id_table[] = {
{ PCI_DEVICE(PCI_VENDOR_ID_CAVIUM, PCI_DEVID_OCTEONTX2_CGX) },
@@ -47,11 +74,24 @@ MODULE_LICENSE("GPL v2");
MODULE_VERSION(DRV_VERSION);
MODULE_DEVICE_TABLE(pci, cgx_id_table);
+static void cgx_write(struct cgx *cgx, u64 lmac, u64 offset, u64 val)
+{
+ writeq(val, cgx->reg_base + (lmac << 18) + offset);
+}
+
static u64 cgx_read(struct cgx *cgx, u64 lmac, u64 offset)
{
return readq(cgx->reg_base + (lmac << 18) + offset);
}
+static inline struct lmac *lmac_pdata(u8 lmac_id, struct cgx *cgx)
+{
+ if (!cgx || lmac_id >= MAX_LMAC_PER_CGX)
+ return NULL;
+
+ return cgx->lmac_idmap[lmac_id];
+}
+
int cgx_get_cgx_cnt(void)
{
struct cgx *cgx_dev;
@@ -87,18 +127,318 @@ void *cgx_get_pdata(int cgx_id)
}
EXPORT_SYMBOL(cgx_get_pdata);
-static void cgx_lmac_init(struct cgx *cgx)
+/* CGX Firmware interface low level support */
+static int cgx_fwi_cmd_send(struct cgx_cmd *cmd, struct cgx_evt_sts *rsp,
+ struct lmac *lmac)
+{
+ struct cgx *cgx = lmac->cgx;
+ union cgx_cmdreg creg;
+ union cgx_evtreg ereg;
+ struct device *dev;
+ int err = 0;
+
+ /* Ensure no other command is in progress */
+ err = mutex_lock_interruptible(&lmac->cmd_lock);
+ if (err)
+ return err;
+
+ /* Ensure command register is free */
+ creg.val = cgx_read(cgx, lmac->lmac_id, CGX_COMMAND_REG);
+ if (creg.cmd.own != CGX_CMD_OWN_NS) {
+ err = -EBUSY;
+ goto unlock;
+ }
+
+ /* Update ownership in command request */
+ cmd->own = CGX_CMD_OWN_FIRMWARE;
+
+ /* Mark this lmac as pending, before we start */
+ lmac->cmd_pend = true;
+
+ /* Start command in hardware */
+ creg.cmd = *cmd;
+ cgx_write(cgx, lmac->lmac_id, CGX_COMMAND_REG, creg.val);
+ creg.val = cgx_read(cgx, lmac->lmac_id, CGX_COMMAND_REG);
+
+ /* Ensure command is completed without errors */
+ if (!wait_event_timeout(lmac->wq_cmd_cmplt, !lmac->cmd_pend,
+ msecs_to_jiffies(CGX_CMD_TIMEOUT))) {
+ dev = &cgx->pdev->dev;
+ ereg.val = cgx_read(cgx, lmac->lmac_id, CGX_EVENT_REG);
+ if (ereg.val) {
+ dev_err(dev, "cgx port %d:%d: No event for response\n",
+ cgx->cgx_id, lmac->lmac_id);
+ /* copy event */
+ lmac->resp = ereg.evt_sts;
+ } else {
+ dev_err(dev, "cgx port %d:%d cmd timeout\n",
+ cgx->cgx_id, lmac->lmac_id);
+ err = -EIO;
+ goto unlock;
+ }
+ }
+
+ /* we have a valid command response */
+ smp_rmb(); /* Ensure the latest updates are visible */
+ *rsp = lmac->resp;
+
+unlock:
+ mutex_unlock(&lmac->cmd_lock);
+
+ return err;
+}
+
+static inline int cgx_fwi_cmd_generic(struct cgx_cmd *req,
+ struct cgx_evt_sts *rsp,
+ struct cgx *cgx, int lmac_id)
+{
+ struct lmac *lmac;
+ int err;
+
+ lmac = lmac_pdata(lmac_id, cgx);
+ if (!lmac)
+ return -ENODEV;
+
+ err = cgx_fwi_cmd_send(req, rsp, lmac);
+
+ /* Check for valid response */
+ if (!err) {
+ if (rsp->stat == CGX_STAT_FAIL)
+ return -EIO;
+ else
+ return 0;
+ }
+
+ return err;
+}
+
+/* Hardware event handlers */
+static inline void cgx_link_change_handler(struct cgx_lnk_sts *lstat,
+ struct lmac *lmac)
+{
+ struct cgx *cgx = lmac->cgx;
+ struct cgx_link_event event;
+ struct device *dev = &cgx->pdev->dev;
+
+ event.lstat = *lstat;
+ event.cgx_id = cgx->cgx_id;
+ event.lmac_id = lmac->lmac_id;
+
+ if (!lmac->event_cb.notify_link_chg) {
+ dev_dbg(dev, "cgx port %d:%d Link change handler null",
+ cgx->cgx_id, lmac->lmac_id);
+ if (lstat->err_type != CGX_ERR_NONE) {
+ dev_err(dev, "cgx port %d:%d Link error %d\n",
+ cgx->cgx_id, lmac->lmac_id, lstat->err_type);
+ }
+ dev_info(dev, "cgx port %d:%d Link status %s, speed %x\n",
+ cgx->cgx_id, lmac->lmac_id,
+ lstat->link_up ? "UP" : "DOWN", lstat->speed);
+ return;
+ }
+
+ if (lmac->event_cb.notify_link_chg(&event, lmac->event_cb.data))
+ dev_err(dev, "event notification failure\n");
+}
+
+static inline bool cgx_cmdresp_is_linkevent(struct cgx_evt_sts *rsp)
+{
+ if (rsp->id == CGX_CMD_LINK_BRING_UP ||
+ rsp->id == CGX_CMD_LINK_BRING_DOWN)
+ return true;
+ else
+ return false;
+}
+
+static inline bool cgx_event_is_linkevent(struct cgx_evt_sts *evt)
+{
+ if (evt->id == CGX_EVT_LINK_CHANGE)
+ return true;
+ else
+ return false;
+}
+
+static irqreturn_t cgx_fwi_event_handler(int irq, void *data)
+{
+ struct lmac *lmac = data;
+ struct cgx *cgx = lmac->cgx;
+ struct cgx_evt_sts event;
+ union cgx_evtreg ereg;
+ struct device *dev;
+
+ ereg.val = cgx_read(cgx, lmac->lmac_id, CGX_EVENT_REG);
+ if (!ereg.evt_sts.ack)
+ return IRQ_NONE;
+
+ dev = &cgx->pdev->dev;
+
+ event = ereg.evt_sts;
+
+ switch (event.evt_type) {
+ case CGX_EVT_CMD_RESP:
+ /* Copy the response. Since only one command is active at a
+ * time, there is no way a response can get overwritten
+ */
+ lmac->resp = event;
+ /* Ensure response is updated before thread context starts */
+ smp_wmb();
+
+ /* There wont be separate events for link change initiated from
+ * software; Hence report the command responses as events
+ */
+ if (cgx_cmdresp_is_linkevent(&event))
+ cgx_link_change_handler(&ereg.link_sts, lmac);
+
+ /* Release thread waiting for completion */
+ lmac->cmd_pend = false;
+ wake_up_interruptible(&lmac->wq_cmd_cmplt);
+ break;
+ case CGX_EVT_ASYNC:
+ if (cgx_event_is_linkevent(&event))
+ cgx_link_change_handler(&ereg.link_sts, lmac);
+ break;
+ default:
+ dev_err(dev, "cgx port %d:%d Unknown event received\n",
+ cgx->cgx_id, lmac->lmac_id);
+ }
+
+ /* Any new event or command response will be posted by firmware
+ * only after the current status is acked.
+ * Ack the interrupt register as well.
+ */
+ cgx_write(lmac->cgx, lmac->lmac_id, CGX_EVENT_REG, 0);
+ cgx_write(lmac->cgx, lmac->lmac_id, CGXX_CMRX_INT, FW_CGX_INT);
+
+ return IRQ_HANDLED;
+}
+
+/* APIs for PHY management using CGX firmware interface */
+
+/* callback registration for hardware events like link change */
+int cgx_lmac_evh_register(struct cgx_event_cb *cb, void *cgxd, int lmac_id)
{
+ struct lmac *lmac;
+ struct cgx *cgx = cgxd;
+
+ lmac = lmac_pdata(lmac_id, cgx);
+ if (!lmac)
+ return -ENODEV;
+
+ lmac->event_cb = *cb;
+
+ return 0;
+}
+EXPORT_SYMBOL(cgx_lmac_evh_register);
+
+static int cgx_fwi_link_change(struct cgx *cgx, int lmac_id, bool enable)
+{
+ struct cgx_cmd req = { 0 };
+ struct cgx_evt_sts rsp;
+
+ if (enable)
+ req.id = CGX_CMD_LINK_BRING_UP;
+ else
+ req.id = CGX_CMD_LINK_BRING_DOWN;
+
+ return cgx_fwi_cmd_generic(&req, &rsp, cgx, lmac_id);
+}
+EXPORT_SYMBOL(cgx_fwi_link_change);
+
+static inline int cgx_fwi_read_version(struct cgx_ver_s *ver, struct cgx *cgx)
+{
+ struct cgx_cmd req = { 0 };
+ union cgx_evtreg event;
+ int err;
+
+ req.id = CGX_CMD_GET_FW_VER;
+
+ err = cgx_fwi_cmd_generic(&req, &event.evt_sts, cgx, 0);
+ if (!err)
+ *ver = event.ver;
+
+ return err;
+}
+
+static int cgx_lmac_verify_fwi_version(struct cgx *cgx)
+{
+ struct cgx_ver_s ver;
+ struct device *dev = &cgx->pdev->dev;
+ int err;
+
+ if (!cgx->lmac_count)
+ return 0;
+
+ err = cgx_fwi_read_version(&ver, cgx);
+ dev_dbg(dev, "Firmware command interface version = %d.%d\n",
+ ver.major_ver, ver.minor_ver);
+ if (err || ver.major_ver != CGX_FIRMWARE_MAJOR_VER ||
+ ver.minor_ver != CGX_FIRMWARE_MINOR_VER)
+ return -EIO;
+ else
+ return 0;
+}
+
+static int cgx_lmac_init(struct cgx *cgx)
+{
+ struct lmac *lmac;
+ int i, err;
+
cgx->lmac_count = cgx_read(cgx, 0, CGXX_CMRX_RX_LMACS) & 0x7;
if (cgx->lmac_count > MAX_LMAC_PER_CGX)
cgx->lmac_count = MAX_LMAC_PER_CGX;
+
+ for (i = 0; i < cgx->lmac_count; i++) {
+ lmac = kcalloc(1, sizeof(struct lmac), GFP_KERNEL);
+ if (!lmac)
+ return -ENOMEM;
+ lmac->name = kcalloc(1, sizeof("cgx_fwi_xxx_yyy"), GFP_KERNEL);
+ if (!lmac->name)
+ return -ENOMEM;
+ sprintf(lmac->name, "cgx_fwi_%d_%d", cgx->cgx_id, i);
+ lmac->lmac_id = i;
+ lmac->cgx = cgx;
+ init_waitqueue_head(&lmac->wq_cmd_cmplt);
+ mutex_init(&lmac->cmd_lock);
+ err = request_irq(pci_irq_vector(cgx->pdev,
+ CGX_LMAC_FWI + i * 9),
+ cgx_fwi_event_handler, 0, lmac->name, lmac);
+ if (err)
+ return err;
+
+ /* Enable interrupt */
+ cgx_write(cgx, lmac->lmac_id, CGXX_CMRX_INT_ENA_W1S,
+ FW_CGX_INT);
+
+ /* Add reference */
+ cgx->lmac_idmap[i] = lmac;
+ }
+
+ return cgx_lmac_verify_fwi_version(cgx);
+}
+
+static int cgx_lmac_exit(struct cgx *cgx)
+{
+ struct lmac *lmac;
+ int i;
+
+ /* Free all lmac related resources */
+ for (i = 0; i < cgx->lmac_count; i++) {
+ lmac = cgx->lmac_idmap[i];
+ if (!lmac)
+ continue;
+ free_irq(pci_irq_vector(cgx->pdev, CGX_LMAC_FWI + i * 9), lmac);
+ kfree(lmac->name);
+ kfree(lmac);
+ }
+
+ return 0;
}
static int cgx_probe(struct pci_dev *pdev, const struct pci_device_id *id)
{
- int err;
struct device *dev = &pdev->dev;
struct cgx *cgx;
+ int err, nvec;
cgx = devm_kzalloc(dev, sizeof(*cgx), GFP_KERNEL);
if (!cgx)
@@ -128,14 +468,28 @@ static int cgx_probe(struct pci_dev *pdev, const struct pci_device_id *id)
goto err_release_regions;
}
+ nvec = CGX_NVEC;
+ err = pci_alloc_irq_vectors(pdev, nvec, nvec, PCI_IRQ_MSIX);
+ if (err < 0 || err != nvec) {
+ dev_err(dev, "Request for %d msix vectors failed, err %d\n",
+ nvec, err);
+ goto err_release_regions;
+ }
+
list_add(&cgx->cgx_list, &cgx_list);
cgx->cgx_id = cgx_get_cgx_cnt() - 1;
- cgx_lmac_init(cgx);
+
+ err = cgx_lmac_init(cgx);
+ if (err)
+ goto err_release_lmac;
+
return 0;
-err_release_regions:
+err_release_lmac:
+ cgx_lmac_exit(cgx);
list_del(&cgx->cgx_list);
+err_release_regions:
pci_release_regions(pdev);
err_disable_device:
pci_disable_device(pdev);
@@ -147,7 +501,9 @@ static void cgx_remove(struct pci_dev *pdev)
{
struct cgx *cgx = pci_get_drvdata(pdev);
+ cgx_lmac_exit(cgx);
list_del(&cgx->cgx_list);
+ pci_free_irq_vectors(pdev);
pci_release_regions(pdev);
pci_disable_device(pdev);
pci_set_drvdata(pdev, NULL);
diff --git a/drivers/soc/marvell/octeontx2/cgx.h b/drivers/soc/marvell/octeontx2/cgx.h
index acdc16e..a2a7a6d 100644
--- a/drivers/soc/marvell/octeontx2/cgx.h
+++ b/drivers/soc/marvell/octeontx2/cgx.h
@@ -11,6 +11,8 @@
#ifndef CGX_H
#define CGX_H
+#include "cgx_fw_if.h"
+
/* PCI device IDs */
#define PCI_DEVID_OCTEONTX2_CGX 0xA059
@@ -22,12 +24,42 @@
#define CGX_OFFSET(x) ((x) * MAX_LMAC_PER_CGX)
/* Registers */
+#define CGXX_CMRX_INT 0x040
+#define FW_CGX_INT BIT_ULL(1)
+#define CGXX_CMRX_INT_ENA_W1S 0x058
#define CGXX_CMRX_RX_ID_MAP 0x060
#define CGXX_CMRX_RX_LMACS 0x128
+#define CGXX_SCRATCH0_REG 0x1050
+#define CGXX_SCRATCH1_REG 0x1058
+#define CGX_CONST 0x2000
+
+#define CGX_COMMAND_REG CGXX_SCRATCH1_REG
+#define CGX_EVENT_REG CGXX_SCRATCH0_REG
+#define CGX_CMD_TIMEOUT 2200 /* msecs */
+
+#define CGX_NVEC 37
+#define CGX_LMAC_FWI 0
+
+struct cgx_link_event {
+ struct cgx_lnk_sts lstat;
+ u8 cgx_id;
+ u8 lmac_id;
+};
+
+/**
+ * struct cgx_event_cb
+ * @notify_link_chg: callback for link change notification
+ * @data: data passed to callback function
+ */
+struct cgx_event_cb {
+ int (*notify_link_chg)(struct cgx_link_event *event, void *data);
+ void *data;
+};
extern struct pci_driver cgx_driver;
int cgx_get_cgx_cnt(void);
int cgx_get_lmac_cnt(void *cgxd);
void *cgx_get_pdata(int cgx_id);
+int cgx_lmac_evh_register(struct cgx_event_cb *cb, void *cgxd, int lmac_id);
#endif /* CGX_H */
diff --git a/drivers/soc/marvell/octeontx2/cgx_fw_if.h b/drivers/soc/marvell/octeontx2/cgx_fw_if.h
new file mode 100644
index 0000000..771dd50
--- /dev/null
+++ b/drivers/soc/marvell/octeontx2/cgx_fw_if.h
@@ -0,0 +1,225 @@
+/* SPDX-License-Identifier: GPL-2.0
+ * Marvell OcteonTx2 CGX driver
+ *
+ * Copyright (C) 2018 Marvell International Ltd.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+
+#ifndef __CGX_FW_INTF_H__
+#define __CGX_FW_INTF_H__
+
+#define CGX_FIRMWARE_MAJOR_VER 1
+#define CGX_FIRMWARE_MINOR_VER 0
+
+#define CGX_EVENT_ACK 1UL
+
+/* CGX error types. set for cmd response status as CGX_STAT_FAIL */
+enum cgx_error_type {
+ CGX_ERR_NONE,
+ CGX_ERR_LMAC_NOT_ENABLED,
+ CGX_ERR_LMAC_MODE_INVALID,
+ CGX_ERR_REQUEST_ID_INVALID,
+ CGX_ERR_PREV_ACK_NOT_CLEAR,
+ CGX_ERR_PHY_LINK_DOWN,
+ CGX_ERR_PCS_RESET_FAIL,
+ CGX_ERR_AN_CPT_FAIL,
+ CGX_ERR_TX_NOT_IDLE,
+ CGX_ERR_RX_NOT_IDLE,
+ CGX_ERR_SPUX_BR_BLKLOCK_FAIL,
+ CGX_ERR_SPUX_RX_ALIGN_FAIL,
+ CGX_ERR_SPUX_TX_FAULT,
+ CGX_ERR_SPUX_RX_FAULT,
+ CGX_ERR_SPUX_RESET_FAIL,
+ CGX_ERR_SPUX_AN_RESET_FAIL,
+ CGX_ERR_SPUX_USX_AN_RESET_FAIL,
+ CGX_ERR_SMUX_RX_LINK_NOT_OK,
+ CGX_ERR_PCS_RECV_LINK_FAIL,
+ CGX_ERR_TRAINING_FAIL,
+ CGX_ERR_RX_EQU_FAIL,
+ CGX_ERR_SPUX_BER_FAIL,
+ CGX_ERR_SPUX_RSFEC_ALGN_FAIL, /* = 22 */
+};
+
+/* LINK speed types */
+enum cgx_link_speed {
+ CGX_LINK_NONE,
+ CGX_LINK_10M,
+ CGX_LINK_100M,
+ CGX_LINK_1G,
+ CGX_LINK_2HG,
+ CGX_LINK_5G,
+ CGX_LINK_10G,
+ CGX_LINK_20G,
+ CGX_LINK_25G,
+ CGX_LINK_40G,
+ CGX_LINK_50G,
+ CGX_LINK_100G,
+ CGX_LINK_SPEED_MAX,
+};
+
+/* REQUEST ID types. Input to firmware */
+enum cgx_cmd_id {
+ CGX_CMD_NONE,
+ CGX_CMD_GET_FW_VER,
+ CGX_CMD_GET_MAC_ADDR,
+ CGX_CMD_SET_MTU,
+ CGX_CMD_GET_LINK_STS, /* optional to user */
+ CGX_CMD_LINK_BRING_UP,
+ CGX_CMD_LINK_BRING_DOWN,
+ CGX_CMD_INTERNAL_LBK,
+ CGX_CMD_EXTERNAL_LBK,
+ CGX_CMD_HIGIG,
+ CGX_CMD_LINK_STATE_CHANGE,
+ CGX_CMD_MODE_CHANGE, /* hot plug support */
+ CGX_CMD_INTF_SHUTDOWN,
+ CGX_CMD_IRQ_ENABLE,
+ CGX_CMD_IRQ_DISABLE,
+};
+
+/* async event ids */
+enum cgx_evt_id {
+ CGX_EVT_NONE,
+ CGX_EVT_LINK_CHANGE,
+};
+
+/* event types - cause of interrupt */
+enum cgx_evt_type {
+ CGX_EVT_ASYNC,
+ CGX_EVT_CMD_RESP
+};
+
+enum cgx_stat {
+ CGX_STAT_SUCCESS,
+ CGX_STAT_FAIL
+};
+
+enum cgx_cmd_own {
+ CGX_CMD_OWN_NS,
+ CGX_CMD_OWN_FIRMWARE,
+};
+
+/* scratchx(0) CSR used for ATF->non-secure SW communication.
+ * This acts as the status register
+ * Provides details on command ack/status, link status, error details
+ */
+struct cgx_evt_sts {
+ uint64_t ack:1;
+ uint64_t evt_type:1; /* cgx_evt_type */
+ uint64_t stat:1; /* cgx_stat */
+ uint64_t id:6; /* cgx_evt_id/cgx_cmd_id */
+ uint64_t reserved:55;
+};
+
+/* Response to command IDs with command status as CGX_STAT_FAIL
+ *
+ * Not applicable for commands :
+ * CGX_CMD_LINK_BRING_UP/DOWN/CGX_EVT_LINK_CHANGE
+ * check struct cgx_lnk_sts comments
+ */
+struct cgx_err_sts_s {
+ uint64_t reserved1:9;
+ uint64_t type:10; /* cgx_error_type */
+ uint64_t reserved2:35;
+};
+
+/* Response to cmd ID as CGX_CMD_GET_FW_VER with cmd status as
+ * CGX_STAT_SUCCESS
+ */
+struct cgx_ver_s {
+ uint64_t reserved1:9;
+ uint64_t major_ver:4;
+ uint64_t minor_ver:4;
+ uint64_t reserved2:47;
+};
+
+/* Response to cmd ID as CGX_CMD_GET_MAC_ADDR with cmd status as
+ * CGX_STAT_SUCCESS
+ */
+struct cgx_mac_addr_s {
+ uint64_t reserved1:9;
+ uint64_t local_mac_addr:48;
+ uint64_t reserved2:7;
+};
+
+/* Response to cmd ID - CGX_CMD_LINK_BRING_UP/DOWN, event ID CGX_EVT_LINK_CHANGE
+ * status can be either CGX_STAT_FAIL or CGX_STAT_SUCCESS
+ *
+ * In case of CGX_STAT_FAIL, it indicates CGX configuration failed
+ * when processing link up/down/change command.
+ * Both err_type and current link status will be updated
+ *
+ * In case of CGX_STAT_SUCCESS, err_type will be CGX_ERR_NONE and current
+ * link status will be updated
+ */
+struct cgx_lnk_sts {
+ uint64_t reserved1:9;
+ uint64_t link_up:1;
+ uint64_t full_duplex:1;
+ uint64_t speed:4; /* cgx_link_speed */
+ uint64_t err_type:10;
+ uint64_t reserved2:39;
+};
+
+union cgx_evtreg {
+ u64 val;
+ struct cgx_evt_sts evt_sts; /* common for all commands/events */
+ struct cgx_lnk_sts link_sts; /* response to LINK_BRINGUP/DOWN/CHANGE */
+ struct cgx_ver_s ver; /* response to CGX_CMD_GET_FW_VER */
+ struct cgx_mac_addr_s mac_addr; /* response to CGX_CMD_GET_MAC_ADDR */
+ struct cgx_err_sts_s err; /* response if evt_status = CMD_FAIL */
+};
+
+/* scratchx(1) CSR used for non-secure SW->ATF communication
+ * This CSR acts as a command register
+ */
+struct cgx_cmd {
+ uint64_t own:2; /* cgx_csr_own */
+ uint64_t id:6; /* cgx_request_id */
+ uint64_t reserved2:56;
+};
+
+/* Any command using enable/disable as an argument need
+ * to pass the option via this structure.
+ * Ex: Loopback, HiGig...
+ */
+struct cgx_ctl_args {
+ uint64_t reserved1:8;
+ uint64_t enable:1;
+ uint64_t reserved2:55;
+};
+
+/* command argument to be passed for cmd ID - CGX_CMD_SET_MTU */
+struct cgx_mtu_args {
+ uint64_t reserved1:8;
+ uint64_t size:16;
+ uint64_t reserved2:40;
+};
+
+/* command argument to be passed for cmd ID - CGX_CMD_LINK_CHANGE */
+struct cgx_link_change_args {
+ uint64_t reserved1:8;
+ uint64_t link_up:1;
+ uint64_t full_duplex:1;
+ uint64_t speed:4; /* cgx_link_speed */
+ uint64_t reserved2:50;
+};
+
+struct cgx_irq_cfg {
+ uint64_t reserved1:8;
+ uint64_t irq_phys:32;
+ uint64_t reserved2:24;
+};
+
+union cgx_cmdreg {
+ u64 val;
+ struct cgx_cmd cmd;
+ struct cgx_ctl_args cmd_args;
+ struct cgx_mtu_args mtu_size;
+ struct cgx_irq_cfg irq_cfg; /* Input to CGX_CMD_IRQ_ENABLE */
+ struct cgx_link_change_args lnk_args;/* Input to CGX_CMD_LINK_CHANGE */
+};
+
+#endif /* __CGX_FW_INTF_H__ */
--
2.7.4
^ permalink raw reply related
* [PATCH v3 14/15] soc: octeontx2: Register for CGX lmac events
From: sunil.kovvuri @ 2018-09-04 16:28 UTC (permalink / raw)
To: linux-kernel, arnd, olof
Cc: linux-arm-kernel, linux-soc, andrew, davem, netdev, Linu Cherian
In-Reply-To: <1536078525-31534-1-git-send-email-sunil.kovvuri@gmail.com>
From: Linu Cherian <lcherian@marvell.com>
Added support in RVU AF driver to register for
CGX LMAC link status change events from firmware
and managing them. Processing part will be added
in followup patches.
- Introduced eventqueue for posting events from cgx lmac.
Queueing mechanism will ensure that events can be posted
and firmware can be acked immediately and hence event
reception and processing are decoupled.
- Events gets added to the queue by notification callback.
Notification callback is expected to be atomic, since it
is called from interrupt context.
- Events are dequeued and processed in a worker thread.
Signed-off-by: Linu Cherian <lcherian@marvell.com>
---
drivers/soc/marvell/octeontx2/rvu.c | 6 +-
drivers/soc/marvell/octeontx2/rvu.h | 5 ++
drivers/soc/marvell/octeontx2/rvu_cgx.c | 101 +++++++++++++++++++++++++++++++-
3 files changed, 108 insertions(+), 4 deletions(-)
diff --git a/drivers/soc/marvell/octeontx2/rvu.c b/drivers/soc/marvell/octeontx2/rvu.c
index faf7d0f..282982f 100644
--- a/drivers/soc/marvell/octeontx2/rvu.c
+++ b/drivers/soc/marvell/octeontx2/rvu.c
@@ -1564,10 +1564,11 @@ static int rvu_probe(struct pci_dev *pdev, const struct pci_device_id *id)
err = rvu_register_interrupts(rvu);
if (err)
- goto err_mbox;
+ goto err_cgx;
return 0;
-
+err_cgx:
+ rvu_cgx_wq_destroy(rvu);
err_mbox:
rvu_mbox_destroy(rvu);
err_hwsetup:
@@ -1589,6 +1590,7 @@ static void rvu_remove(struct pci_dev *pdev)
struct rvu *rvu = pci_get_drvdata(pdev);
rvu_unregister_interrupts(rvu);
+ rvu_cgx_wq_destroy(rvu);
rvu_mbox_destroy(rvu);
rvu_reset_all_blocks(rvu);
rvu_free_hw_resources(rvu);
diff --git a/drivers/soc/marvell/octeontx2/rvu.h b/drivers/soc/marvell/octeontx2/rvu.h
index 385f597..d169fa9 100644
--- a/drivers/soc/marvell/octeontx2/rvu.h
+++ b/drivers/soc/marvell/octeontx2/rvu.h
@@ -110,6 +110,10 @@ struct rvu {
* every cgx lmac port
*/
void **cgx_idmap; /* cgx id to cgx data map table */
+ struct work_struct cgx_evh_work;
+ struct workqueue_struct *cgx_evh_wq;
+ spinlock_t cgx_evq_lock; /* cgx event queue lock */
+ struct list_head cgx_evq_head; /* cgx event queue head */
};
static inline void rvu_write64(struct rvu *rvu, u64 block, u64 offset, u64 val)
@@ -150,4 +154,5 @@ int rvu_poll_reg(struct rvu *rvu, u64 block, u64 offset, u64 mask, bool zero);
/* CGX APIs */
int rvu_cgx_probe(struct rvu *rvu);
+void rvu_cgx_wq_destroy(struct rvu *rvu);
#endif /* RVU_H */
diff --git a/drivers/soc/marvell/octeontx2/rvu_cgx.c b/drivers/soc/marvell/octeontx2/rvu_cgx.c
index bf81507..2359806e 100644
--- a/drivers/soc/marvell/octeontx2/rvu_cgx.c
+++ b/drivers/soc/marvell/octeontx2/rvu_cgx.c
@@ -15,6 +15,11 @@
#include "rvu.h"
#include "cgx.h"
+struct cgx_evq_entry {
+ struct list_head evq_node;
+ struct cgx_link_event link_event;
+};
+
static inline u8 cgxlmac_id_to_bmap(u8 cgx_id, u8 lmac_id)
{
return ((cgx_id & 0xF) << 4) | (lmac_id & 0xF);
@@ -72,9 +77,95 @@ static int rvu_map_cgx_lmac_pf(struct rvu *rvu)
return 0;
}
+/* This is called from interrupt context and is expected to be atomic */
+static int cgx_lmac_postevent(struct cgx_link_event *event, void *data)
+{
+ struct rvu *rvu = data;
+ struct cgx_evq_entry *qentry;
+
+ /* post event to the event queue */
+ qentry = kmalloc(sizeof(*qentry), GFP_ATOMIC);
+ if (!qentry)
+ return -ENOMEM;
+ qentry->link_event = *event;
+ spin_lock(&rvu->cgx_evq_lock);
+ list_add_tail(&qentry->evq_node, &rvu->cgx_evq_head);
+ spin_unlock(&rvu->cgx_evq_lock);
+
+ /* start worker to process the events */
+ queue_work(rvu->cgx_evh_wq, &rvu->cgx_evh_work);
+
+ return 0;
+}
+
+static void cgx_evhandler_task(struct work_struct *work)
+{
+ struct rvu *rvu = container_of(work, struct rvu, cgx_evh_work);
+ struct cgx_evq_entry *qentry;
+ struct cgx_link_event *event;
+ unsigned long flags;
+
+ do {
+ /* Dequeue an event */
+ spin_lock_irqsave(&rvu->cgx_evq_lock, flags);
+ qentry = list_first_entry_or_null(&rvu->cgx_evq_head,
+ struct cgx_evq_entry,
+ evq_node);
+ if (qentry)
+ list_del(&qentry->evq_node);
+ spin_unlock_irqrestore(&rvu->cgx_evq_lock, flags);
+ if (!qentry)
+ break; /* nothing more to process */
+
+ event = &qentry->link_event;
+
+ /* Do nothing for now */
+ kfree(qentry);
+ } while (1);
+}
+
+static void cgx_lmac_event_handler_init(struct rvu *rvu)
+{
+ struct cgx_event_cb cb;
+ int cgx, lmac, err;
+ void *cgxd;
+
+ spin_lock_init(&rvu->cgx_evq_lock);
+ INIT_LIST_HEAD(&rvu->cgx_evq_head);
+ INIT_WORK(&rvu->cgx_evh_work, cgx_evhandler_task);
+ rvu->cgx_evh_wq = alloc_workqueue("rvu_evh_wq", 0, 0);
+ if (!rvu->cgx_evh_wq) {
+ dev_err(rvu->dev, "alloc workqueue failed");
+ return;
+ }
+
+ cb.notify_link_chg = cgx_lmac_postevent; /* link change call back */
+ cb.data = rvu;
+
+ for (cgx = 0; cgx < rvu->cgx_cnt; cgx++) {
+ cgxd = rvu_cgx_pdata(cgx, rvu);
+ for (lmac = 0; lmac < cgx_get_lmac_cnt(cgxd); lmac++) {
+ err = cgx_lmac_evh_register(&cb, cgxd, lmac);
+ if (err)
+ dev_err(rvu->dev,
+ "%d:%d handler register failed\n",
+ cgx, lmac);
+ }
+ }
+}
+
+void rvu_cgx_wq_destroy(struct rvu *rvu)
+{
+ if (rvu->cgx_evh_wq) {
+ flush_workqueue(rvu->cgx_evh_wq);
+ destroy_workqueue(rvu->cgx_evh_wq);
+ rvu->cgx_evh_wq = NULL;
+ }
+}
+
int rvu_cgx_probe(struct rvu *rvu)
{
- int i;
+ int i, err;
/* find available cgx ports */
rvu->cgx_cnt = cgx_get_cgx_cnt();
@@ -93,5 +184,11 @@ int rvu_cgx_probe(struct rvu *rvu)
rvu->cgx_idmap[i] = cgx_get_pdata(i);
/* Map CGX LMAC interfaces to RVU PFs */
- return rvu_map_cgx_lmac_pf(rvu);
+ err = rvu_map_cgx_lmac_pf(rvu);
+ if (err)
+ return err;
+
+ /* Register for CGX events */
+ cgx_lmac_event_handler_init(rvu);
+ return 0;
}
--
2.7.4
^ permalink raw reply related
* [PATCH v3 15/15] MAINTAINERS: Add entry for Marvell OcteonTX2 Admin Function driver
From: sunil.kovvuri @ 2018-09-04 16:28 UTC (permalink / raw)
To: linux-kernel, arnd, olof
Cc: linux-arm-kernel, linux-soc, andrew, davem, netdev, Sunil Goutham
In-Reply-To: <1536078525-31534-1-git-send-email-sunil.kovvuri@gmail.com>
From: Sunil Goutham <sgoutham@marvell.com>
Added maintainers entry for Marvell OcteonTX2 SOC's RVU
admin function driver.
Signed-off-by: Sunil Goutham <sgoutham@marvell.com>
---
MAINTAINERS | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/MAINTAINERS b/MAINTAINERS
index e178f2b..38f874c 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -8748,6 +8748,16 @@ S: Supported
F: drivers/mmc/host/sdhci-xenon*
F: Documentation/devicetree/bindings/mmc/marvell,xenon-sdhci.txt
+MARVELL OCTEONTX2 RVU ADMIN FUNCTION DRIVER
+M: Sunil Goutham <sgoutham@marvell.com>
+M: Linu Cherian <lcherian@marvell.com>
+M: Geetha sowjanya <gakula@marvell.com>
+M: Jerin Jacob <jerinj@marvell.com>
+L: linux-kernel@vger.kernel.org
+L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
+S: Maintained
+F: drivers/soc/marvell/octeontx2
+
MATROX FRAMEBUFFER DRIVER
L: linux-fbdev@vger.kernel.org
S: Orphan
--
2.7.4
^ permalink raw reply related
* Re: [PATCH mlx5-next] net/mlx5: Fix atomic_mode enum values
From: Leon Romanovsky @ 2018-09-04 12:05 UTC (permalink / raw)
To: Doug Ledford, Jason Gunthorpe
Cc: Moni Shoua, RDMA mailing list, Artemy Kovalyov, Saeed Mahameed,
linux-netdev
In-Reply-To: <20180903171928.19348-1-leon@kernel.org>
[-- Attachment #1: Type: text/plain, Size: 711 bytes --]
On Mon, Sep 03, 2018 at 08:19:28PM +0300, Leon Romanovsky wrote:
> From: Moni Shoua <monis@mellanox.com>
>
> The field atomic_mode is 4 bits wide and therefore can hold values
> from 0x0 to 0xf. Remove the unnecessary 20 bit shift that made the values
> be incorrect. While that, remove unused enum values.
>
> Fixes: 57cda166bbe0 ("net/mlx5: Add DCT command interface")
> Signed-off-by: Moni Shoua <monis@mellanox.com>
> Reviewed-by: Artemy Kovalyov <artemyko@mellanox.com>
> Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
> ---
> include/linux/mlx5/driver.h | 5 +----
> 1 file changed, 1 insertion(+), 4 deletions(-)
>
Applied to mlx5-next: aa7e80b220f3 net/mlx5: Fix atomic_mode enum values
Thanks
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 801 bytes --]
^ permalink raw reply
* Re: [PATCH mlx5-next] net/mlx5: Add memic command opcode to command checker
From: Leon Romanovsky @ 2018-09-04 12:06 UTC (permalink / raw)
To: Doug Ledford, Jason Gunthorpe
Cc: Ariel Levkovich, RDMA mailing list, Saeed Mahameed, linux-netdev
In-Reply-To: <20180903171948.19461-1-leon@kernel.org>
[-- Attachment #1: Type: text/plain, Size: 581 bytes --]
On Mon, Sep 03, 2018 at 08:19:48PM +0300, Leon Romanovsky wrote:
> From: Ariel Levkovich <lariel@mellanox.com>
>
> Adding the alloc/dealloc memic FW command opcodes to
> avoid "unknown command" prints in the command string
> converter and internal error status handler.
>
> Signed-off-by: Ariel Levkovich <lariel@mellanox.com>
> Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
> ---
> drivers/net/ethernet/mellanox/mlx5/core/cmd.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
Applied to mlx5-next: 09adbb5dd01b net/mlx5: Add memic command opcode to command checker
Thanks
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 801 bytes --]
^ permalink raw reply
* Re: [PATCH net-next 1/2] net: stmmac: Rework coalesce timer and fix multi-queue races
From: Jerome Brunet @ 2018-09-04 12:27 UTC (permalink / raw)
To: Jose Abreu, netdev
Cc: Martin Blumenstingl, David S. Miller, Joao Pinto,
Giuseppe Cavallaro, Alexandre Torgue
In-Reply-To: <3474351f-040f-bdef-1085-2b0958983071@synopsys.com>
On Tue, 2018-09-04 at 10:57 +0100, Jose Abreu wrote:
> Hi Jerome,
>
> On 03-09-2018 17:22, Jerome Brunet wrote:
> >
> > Situation is even worse with this.
> > I'm using an NFS root filesystem. With your fixup, I'm not reaching the prompt
> > anymore. Looks like a the same kind of network breakdown we had previously
> >
>
> I was able to reproduce your problem and the attached fixup patch
> fixed it up for me. Can you please try?
I suppose this applies on top the initial patch, not the previous fixup
(judging from the rejection) Could you details the baseline for each
patch you send, its not easy to follow.
BTW, there something weird (at least for me) with the patch you attach.
git always refuse to apply them and even patch complains:
git apply fixup2.patch
error: patch failed: drivers/net/ethernet/stmicro/stmmac/stmmac_main.c:1861
error: drivers/net/ethernet/stmicro/stmmac/stmmac_main.c: patch does not apply
patch -p1 < fixup2.patch
(Stripping trailing CRs from patch; use --binary to disable.)
patching file drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
Hunk #6 succeeded at 2252 (offset 1 line).
patch unexpectedly ends in middle of line
patch unexpectedly ends in middle of line
Anyway, with this second fixup, I'm back to square one:
I can boot but iperf3 won't hold for long
# iperf3 -c 10.1.2.124 -p 12345 -t 600
Connecting to host 10.1.2.124, port 12345
[ 4] local 10.1.4.59 port 38650 connected to 10.1.2.124 port 12345
[ ID] Interval Transfer Bandwidth Retr Cwnd
[ 4] 0.00-1.00 sec 80.8 MBytes 678 Mbits/sec 1 300 KBytes
[ 4] 1.00-2.00 sec 81.1 MBytes 680 Mbits/sec 0 329 KBytes
[ 4] 2.00-3.00 sec 80.7 MBytes 677 Mbits/sec 0 335 KBytes
[ 4] 3.00-4.00 sec 81.7 MBytes 685 Mbits/sec 0 337 KBytes
[ 4] 4.00-5.00 sec 81.0 MBytes 680 Mbits/sec 0 341 KBytes
[ 4] 5.00-6.00 sec 81.0 MBytes 680 Mbits/sec 0 344 KBytes
[ 4] 6.00-7.00 sec 80.7 MBytes 677 Mbits/sec 0 345 KBytes
[ 4] 7.00-8.00 sec 81.5 MBytes 684 Mbits/sec 0 346 KBytes
[ 4] 8.00-9.00 sec 81.2 MBytes 680 Mbits/sec 0 348 KBytes
[ 4] 9.00-10.00 sec 5.59 MBytes 46.9 Mbits/sec 2 1.41 KBytes
[ 4] 10.00-11.00 sec 0.00 Bytes 0.00 bits/sec 1 1.41 KBytes
[ 4] 11.00-12.00 sec 0.00 Bytes 0.00 bits/sec 0 1.41 KBytes
[ 4] 12.00-13.00 sec 0.00 Bytes 0.00 bits/sec 1 1.41 KBytes
[ 4] 13.00-14.00 sec 0.00 Bytes 0.00 bits/sec 0 1.41 KBytes
>
> Thanks and Best Regards,
> Jose Miguel Abreu
^ permalink raw reply
* Re: [PATCH] rtl8xxxu: Add rtl8188ctv support
From: Jes Sorensen @ 2018-09-04 17:08 UTC (permalink / raw)
To: Aleksei Mamlin
Cc: Kalle Valo, David S . Miller, linux-wireless, netdev,
linux-kernel
In-Reply-To: <20180904192338.e9be91d4be447e33acefed5a@gmail.com>
On 09/04/2018 12:23 PM, Aleksei Mamlin wrote:
> On Tue, 4 Sep 2018 11:36:50 -0400
> Jes Sorensen <jes.sorensen@gmail.com> wrote:
>
>> On 09/04/2018 04:16 AM, Kalle Valo wrote:
>>> Aleksei Mamlin <mamlinav@gmail.com> wrote:
>>>
>>>> The Realtek rtl8188ctv (0x0bda:0x018a) is a highly integrated single-chip
>>>> WLAN USB2.0 network interface controller.
>>>>
>>>> Currently rtl8188ctv is supported by rtlwifi driver.
>>>> It is similar to the rtl8188cus(0x0bda:0x818a) and uses the same config.
>>>>
>>>> Signed-off-by: Aleksei Mamlin <mamlinav@gmail.com>
>>>
>>> Patch applied to wireless-drivers-next.git, thanks.
>>>
>>> 514502c3a70b rtl8xxxu: Add rtl8188ctv support
>>
>> Looks good to me too - assume it's been tested?
>>
>
> Yes, tested on my ARM tablet. It successfully connected to my home router
> using wpa_supplicant. There is dmesg output:
Awesome, glad to hear it's working!
Jes
^ permalink raw reply
* Re: [PATCH v2 00/11] mscc: ocelot: add support for SerDes muxing configuration
From: David Miller @ 2018-09-04 17:17 UTC (permalink / raw)
To: alexandre.belloni
Cc: andrew, quentin.schulz, ralf, paul.burton, jhogan, robh+dt,
mark.rutland, kishon, f.fainelli, allan.nielsen, linux-mips,
devicetree, linux-kernel, netdev, thomas.petazzoni
In-Reply-To: <20180904151653.GI13888@piout.net>
From: Alexandre Belloni <alexandre.belloni@bootlin.com>
Date: Tue, 4 Sep 2018 17:16:53 +0200
> What I meant was that 1/11 and 8/11 should go through MIPS because of
> the potential conflicts. The other patches can go through net-next as
> that will make more sense. Maybe Quentin can split the series in two,
> one for MIPS and one for net if that makes it easier for you to apply.
It would make things easier for me.
^ permalink raw reply
* [PATCH V2 0/4 next] net: lan78xx: Minor improvements
From: Stefan Wahren @ 2018-09-04 17:29 UTC (permalink / raw)
To: Woojung Huh
Cc: Microchip Linux Driver Support, David S. Miller, netdev,
linux-usb, linux-kernel, Stefan Wahren
This patch series contains some minor improvements for the lan78xx
driver.
Changes in V2:
- Keep Copyright comment as multi-line
- Add Raghuram's Reviewed-by
Stefan Wahren (4):
net: lan78xx: Bail out if lan78xx_get_endpoints fails
net: lan78xx: Drop unnecessary strcpy in lan78xx_probe
net: lan78xx: Switch to SPDX identifier
net: lan78xx: Make declaration style consistent
drivers/net/usb/lan78xx.c | 34 +++++++++++++---------------------
drivers/net/usb/lan78xx.h | 14 +-------------
2 files changed, 14 insertions(+), 34 deletions(-)
--
2.7.4
^ permalink raw reply
* [PATCH V2 1/4 next] net: lan78xx: Bail out if lan78xx_get_endpoints fails
From: Stefan Wahren @ 2018-09-04 17:29 UTC (permalink / raw)
To: Woojung Huh
Cc: Microchip Linux Driver Support, David S. Miller, netdev,
linux-usb, linux-kernel, Stefan Wahren
In-Reply-To: <1536082152-3669-1-git-send-email-stefan.wahren@i2se.com>
We need to bail out if lan78xx_get_endpoints() fails, otherwise the
result is overwritten.
Fixes: 55d7de9de6c3 ("Microchip's LAN7800 family USB 2/3 to 10/100/1000 Ethernet")
Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
Reviewed-by: Raghuram Chary Jallipalli <raghuramchary.jallipalli@microchip.com>
---
drivers/net/usb/lan78xx.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/drivers/net/usb/lan78xx.c b/drivers/net/usb/lan78xx.c
index a9991c5..3f70b94 100644
--- a/drivers/net/usb/lan78xx.c
+++ b/drivers/net/usb/lan78xx.c
@@ -2952,6 +2952,11 @@ static int lan78xx_bind(struct lan78xx_net *dev, struct usb_interface *intf)
int i;
ret = lan78xx_get_endpoints(dev, intf);
+ if (ret) {
+ netdev_warn(dev->net, "lan78xx_get_endpoints failed: %d\n",
+ ret);
+ return ret;
+ }
dev->data[0] = (unsigned long)kzalloc(sizeof(*pdata), GFP_KERNEL);
--
2.7.4
^ permalink raw reply related
* [PATCH V2 2/4 next] net: lan78xx: Drop unnecessary strcpy in lan78xx_probe
From: Stefan Wahren @ 2018-09-04 17:29 UTC (permalink / raw)
To: Woojung Huh
Cc: Microchip Linux Driver Support, David S. Miller, netdev,
linux-usb, linux-kernel, Stefan Wahren
In-Reply-To: <1536082152-3669-1-git-send-email-stefan.wahren@i2se.com>
There is no need for this strcpy because alloc_etherdev() already
does this job.
Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
Reviewed-by: Raghuram Chary Jallipalli <raghuramchary.jallipalli@microchip.com>
---
drivers/net/usb/lan78xx.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/net/usb/lan78xx.c b/drivers/net/usb/lan78xx.c
index 3f70b94..3d505c2 100644
--- a/drivers/net/usb/lan78xx.c
+++ b/drivers/net/usb/lan78xx.c
@@ -3766,7 +3766,6 @@ static int lan78xx_probe(struct usb_interface *intf,
ret = lan78xx_bind(dev, intf);
if (ret < 0)
goto out2;
- strcpy(netdev->name, "eth%d");
if (netdev->mtu > (dev->hard_mtu - netdev->hard_header_len))
netdev->mtu = dev->hard_mtu - netdev->hard_header_len;
--
2.7.4
^ permalink raw reply related
* [PATCH V2 3/4 next] net: lan78xx: Switch to SPDX identifier
From: Stefan Wahren @ 2018-09-04 17:29 UTC (permalink / raw)
To: Woojung Huh
Cc: Microchip Linux Driver Support, David S. Miller, netdev,
linux-usb, linux-kernel, Stefan Wahren
In-Reply-To: <1536082152-3669-1-git-send-email-stefan.wahren@i2se.com>
Adopt the SPDX license identifier headers to ease license compliance
management.
Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
---
drivers/net/usb/lan78xx.c | 14 +-------------
drivers/net/usb/lan78xx.h | 14 +-------------
2 files changed, 2 insertions(+), 26 deletions(-)
diff --git a/drivers/net/usb/lan78xx.c b/drivers/net/usb/lan78xx.c
index 3d505c2..e1c055d 100644
--- a/drivers/net/usb/lan78xx.c
+++ b/drivers/net/usb/lan78xx.c
@@ -1,18 +1,6 @@
+// SPDX-License-Identifier: GPL-2.0+
/*
* Copyright (C) 2015 Microchip Technology
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, see <http://www.gnu.org/licenses/>.
*/
#include <linux/version.h>
#include <linux/module.h>
diff --git a/drivers/net/usb/lan78xx.h b/drivers/net/usb/lan78xx.h
index 25aa546..968e5e5 100644
--- a/drivers/net/usb/lan78xx.h
+++ b/drivers/net/usb/lan78xx.h
@@ -1,18 +1,6 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright (C) 2015 Microchip Technology
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, see <http://www.gnu.org/licenses/>.
*/
#ifndef _LAN78XX_H
#define _LAN78XX_H
--
2.7.4
^ permalink raw reply related
* [PATCH V2 4/4 next] net: lan78xx: Make declaration style consistent
From: Stefan Wahren @ 2018-09-04 17:29 UTC (permalink / raw)
To: Woojung Huh
Cc: Microchip Linux Driver Support, David S. Miller, netdev,
linux-usb, linux-kernel, Stefan Wahren
In-Reply-To: <1536082152-3669-1-git-send-email-stefan.wahren@i2se.com>
This patch makes some declaration more consistent.
Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
Reviewed-by: Raghuram Chary Jallipalli <raghuramchary.jallipalli@microchip.com>
---
drivers/net/usb/lan78xx.c | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/drivers/net/usb/lan78xx.c b/drivers/net/usb/lan78xx.c
index e1c055d..331bc99 100644
--- a/drivers/net/usb/lan78xx.c
+++ b/drivers/net/usb/lan78xx.c
@@ -1015,7 +1015,7 @@ static int lan78xx_dataport_write(struct lan78xx_net *dev, u32 ram_select,
static void lan78xx_set_addr_filter(struct lan78xx_priv *pdata,
int index, u8 addr[ETH_ALEN])
{
- u32 temp;
+ u32 temp;
if ((pdata) && (index > 0) && (index < NUM_OF_MAF)) {
temp = addr[3];
@@ -2690,7 +2690,7 @@ static void lan78xx_terminate_urbs(struct lan78xx_net *dev)
static int lan78xx_stop(struct net_device *net)
{
- struct lan78xx_net *dev = netdev_priv(net);
+ struct lan78xx_net *dev = netdev_priv(net);
if (timer_pending(&dev->stat_monitor))
del_timer_sync(&dev->stat_monitor);
@@ -3073,7 +3073,7 @@ static void lan78xx_rx_vlan_offload(struct lan78xx_net *dev,
static void lan78xx_skb_return(struct lan78xx_net *dev, struct sk_buff *skb)
{
- int status;
+ int status;
if (test_bit(EVENT_RX_PAUSED, &dev->flags)) {
skb_queue_tail(&dev->rxq_pause, skb);
@@ -3633,10 +3633,10 @@ static void intr_complete(struct urb *urb)
static void lan78xx_disconnect(struct usb_interface *intf)
{
- struct lan78xx_net *dev;
- struct usb_device *udev;
- struct net_device *net;
- struct phy_device *phydev;
+ struct lan78xx_net *dev;
+ struct usb_device *udev;
+ struct net_device *net;
+ struct phy_device *phydev;
dev = usb_get_intfdata(intf);
usb_set_intfdata(intf, NULL);
--
2.7.4
^ permalink raw reply related
* Re: Why not use all the syn queues? in the function "tcp_conn_request", I have some questions.
From: Neal Cardwell @ 2018-09-04 13:06 UTC (permalink / raw)
To: ttttabcd; +Cc: Netdev
In-Reply-To: <47NgfBCN4YlW5rstCQGVJicSQ3yqiWFZpYPuBnmE1Jer0vxuBffWYbZzM2VmkeNNdk8gFgnMYo5T1fODpWGiRKnElyAY7bUmS_r-Z-SSaf4=@protonmail.com>
On Tue, Sep 4, 2018 at 1:48 AM Ttttabcd <ttttabcd@protonmail.com> wrote:
>
> Hello everyone,recently I am looking at the source code for handling TCP three-way handshake(Linux Kernel version 4.18.5).
>
> I found some strange places in the source code for handling syn messages.
>
> in the function "tcp_conn_request"
>
> This code will be executed when we don't enable the syn cookies.
>
> if (!net->ipv4.sysctl_tcp_syncookies &&
> (net->ipv4.sysctl_max_syn_backlog - inet_csk_reqsk_queue_len(sk) <
> (net->ipv4.sysctl_max_syn_backlog >> 2)) &&
> !tcp_peer_is_proven(req, dst)) {
> /* Without syncookies last quarter of
> * backlog is filled with destinations,
> * proven to be alive.
> * It means that we continue to communicate
> * to destinations, already remembered
> * to the moment of synflood.
> */
> pr_drop_req(req, ntohs(tcp_hdr(skb)->source),
> rsk_ops->family);
> goto drop_and_release;
> }
>
> But why don't we use all the syn queues?
If tcp_peer_is_proven() returns true then we do allow ourselves to use
the whole queue.
> Why do we need to leave the size of (net->ipv4.sysctl_max_syn_backlog >> 2) in the queue?
>
> Even if the system is attacked by a syn flood, there is no need to leave a part. Why do we need to leave a part?
The comment describes the rationale. If syncookies are disabled, then
the last quarter of the backlog is reserved for filling with
destinations that were proven to be alive, according to
tcp_peer_is_proven() (which uses RTTs measured in previous
connections). The idea is that if there is a SYN flood, we do not want
to use all of our queue budget on attack traffic but instead want to
reserve some queue space for SYNs from real remote machines that we
have actually contacted in the past.
> The value of sysctl_max_syn_backlog is the maximum length of the queue only if syn cookies are enabled.
Even if syncookies are disabled, sysctl_max_syn_backlog is the maximum
length of the queue.
> This is the first strange place, here is another strange place
>
> __u32 isn = TCP_SKB_CB(skb)->tcp_tw_isn;
>
> if ((net->ipv4.sysctl_tcp_syncookies == 2 ||
> inet_csk_reqsk_queue_is_full(sk)) && !isn) {
>
> if (!want_cookie && !isn) {
>
> The value of "isn" comes from TCP_SKB_CB(skb)->tcp_tw_isn, then it is judged twice whether its value is indeed 0.
>
> But "tcp_tw_isn" is initialized in the function "tcp_v4_fill_cb"
>
> TCP_SKB_CB(skb)->tcp_tw_isn = 0;
>
> So it has always been 0, I used printk to test, and the result is always 0.
That field is also set in tcp_timewait_state_process():
TCP_SKB_CB(skb)->tcp_tw_isn = isn;
So there can be cases where it is not 0.
Hope that helps,
neal
^ permalink raw reply
* [PATCH] mac80211: remove unnecessary NULL check
From: Gustavo A. R. Silva @ 2018-09-04 13:20 UTC (permalink / raw)
To: Alexander Wetzel, Johannes Berg, David S. Miller
Cc: linux-wireless, netdev, linux-kernel, Gustavo A. R. Silva
Both old and new cannot be NULL at the same time, hence checking
new when old is not NULL is unnecessary.
Also, notice that new is being dereferenced before it is checked:
idx = new->conf.keyidx;
The above triggers a static code analysis warning.
Address this by removing the NULL check on new and adding a code
comment based on the following piece of code:
387 /* caller must provide at least one old/new */
388 if (WARN_ON(!new && !old))
389 return 0;
Addresses-Coverity-ID: 1473176 ("Dereference before null check")
Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
---
net/mac80211/key.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/net/mac80211/key.c b/net/mac80211/key.c
index d6eeace..4700718 100644
--- a/net/mac80211/key.c
+++ b/net/mac80211/key.c
@@ -401,8 +401,9 @@ static int ieee80211_key_replace(struct ieee80211_sub_if_data *sdata,
* pairwise keys.*/
ret = ieee80211_hw_key_replace(old, new, pairwise);
} else {
+ /* new must be provided in case old is not */
idx = new->conf.keyidx;
- if (new && !new->local->wowlan)
+ if (!new->local->wowlan)
ret = ieee80211_key_enable_hw_accel(new);
else
ret = 0;
--
2.7.4
^ permalink raw reply related
* Re: [PATCH net-next v2 1/7] net: phy: mscc: factorize code for LEDs mode
From: David Miller @ 2018-09-04 17:48 UTC (permalink / raw)
To: quentin.schulz
Cc: robh+dt, mark.rutland, andrew, f.fainelli, allan.nielsen, netdev,
devicetree, linux-kernel, thomas.petazzoni
In-Reply-To: <20180903084853.18092-1-quentin.schulz@bootlin.com>
From: Quentin Schulz <quentin.schulz@bootlin.com>
Date: Mon, 3 Sep 2018 10:48:47 +0200
> LEDs modes are set the same way, except they are offset by 4 times the
> index of the LED.
>
> Let's factorize all the code so that it's easier to add support for the
> 4 LEDs of the VSC8584 PHY.
>
> Signed-off-by: Quentin Schulz <quentin.schulz@bootlin.com>
Entire series applied to net-next.
Please provide a proper "0/N ..." cover letter next time.
Thank you.
^ permalink raw reply
* Re: [PATCH] [RFC v2] Drop all 00-INDEX files from Documentation/
From: Mike Rapoport @ 2018-09-04 17:56 UTC (permalink / raw)
To: Henrik Austad
Cc: Mark Rutland, linux-mips, linux-fbdev, x86, kvm, linux-doc,
Peter Zijlstra, James Hogan, Linus Walleij, Will Deacon,
dri-devel, Masahiro Yamada, Jan Kandziora, Paul Mackerras,
Henrik Austad, Pavel Machek, H. Peter Anvin, Evgeniy Polyakov,
linux-s390, Ian Kent, linux-security-module, Paul Moore,
Jonathan Corbet, Helge Deller, Radim Krčmář,
James E.J. Bottomley
In-Reply-To: <1536012923-16275-1-git-send-email-henrik@austad.us>
On Tue, Sep 04, 2018 at 12:15:23AM +0200, Henrik Austad wrote:
> This is a respin with a wider audience (all that get_maintainer returned)
> and I know this spams a *lot* of people. Not sure what would be the correct
> way, so my apologies for ruining your inbox.
>
> The 00-INDEX files are supposed to give a summary of all files present
> in a directory, but these files are horribly out of date and their
> usefulness is brought into question. Often a simple "ls" would reveal
> the same information as the filenames are generally quite descriptive as
> a short introduction to what the file covers (it should not surprise
> anyone what Documentation/sched/sched-design-CFS.txt covers)
>
> A few years back it was mentioned that these files were no longer really
> needed, and they have since then grown further out of date, so perhaps
> it is time to just throw them out.
>
> A short status yields the following _outdated_ 00-INDEX files, first
> counter is files listed in 00-INDEX but missing in the directory, last
> is files present but not listed in 00-INDEX.
>
> List of outdated 00-INDEX:
> Documentation: (4/10)
> Documentation/sysctl: (0/1)
> Documentation/timers: (1/0)
> Documentation/blockdev: (3/1)
> Documentation/w1/slaves: (0/1)
> Documentation/locking: (0/1)
> Documentation/devicetree: (0/5)
> Documentation/power: (1/1)
> Documentation/powerpc: (0/5)
> Documentation/arm: (1/0)
> Documentation/x86: (0/9)
> Documentation/x86/x86_64: (1/1)
> Documentation/scsi: (4/4)
> Documentation/filesystems: (2/9)
> Documentation/filesystems/nfs: (0/2)
> Documentation/cgroup-v1: (0/2)
> Documentation/kbuild: (0/4)
> Documentation/spi: (1/0)
> Documentation/virtual/kvm: (1/0)
> Documentation/scheduler: (0/2)
> Documentation/fb: (0/1)
> Documentation/block: (0/1)
> Documentation/networking: (6/37)
> Documentation/vm: (1/3)
>
> Then there are 364 subdirectories in Documentation/ with several files that
> are missing 00-INDEX alltogether (and another 120 with a single file and no
> 00-INDEX).
>
> I don't really have an opinion to whether or not we /should/ have 00-INDEX,
> but the above 00-INDEX should either be removed or be kept up to date. If
> we should keep the files, I can try to keep them updated, but I rather not
> if we just want to delete them anyway.
>
> As a starting point, remove all index-files and references to 00-INDEX and
> see where the discussion is going.
For the Documentation/vm
Acked-by: Mike Rapoport <rppt@linux.vnet.ibm.com>
> Again, sorry for the insanely wide distribution.
>
> Signed-off-by: Henrik Austad <henrik@austad.us>
> Cc: Jonathan Corbet <corbet@lwn.net>
> Cc: Bjorn Helgaas <bhelgaas@google.com>
> Cc: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
> Cc: Josh Triplett <josh@joshtriplett.org>
> Cc: Steven Rostedt <rostedt@goodmis.org>
> Cc: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
> Cc: Lai Jiangshan <jiangshanlai@gmail.com>
> Cc: Jens Axboe <axboe@kernel.dk>
> Cc: Rob Herring <robh+dt@kernel.org>
> Cc: Mark Rutland <mark.rutland@arm.com>
> Cc: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
> Cc: Linus Walleij <linus.walleij@linaro.org>
> Cc: "David S. Miller" <davem@davemloft.net>
> Cc: Karsten Keil <isdn@linux-pingi.de>
> Cc: Masahiro Yamada <yamada.masahiro@socionext.com>
> Cc: Michal Marek <michal.lkml@markovi.net>
> Cc: Peter Zijlstra <peterz@infradead.org>
> Cc: Ingo Molnar <mingo@redhat.com>
> Cc: Will Deacon <will.deacon@arm.com>
> Cc: Ralf Baechle <ralf@linux-mips.org>
> Cc: Paul Burton <paul.burton@mips.com>
> Cc: James Hogan <jhogan@kernel.org>
> Cc: Paul Moore <paul@paul-moore.com>
> Cc: "James E.J. Bottomley" <jejb@parisc-linux.org>
> Cc: Helge Deller <deller@gmx.de>
> Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>
> Cc: Len Brown <len.brown@intel.com>
> Cc: Pavel Machek <pavel@ucw.cz>
> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
> Cc: Paul Mackerras <paulus@samba.org>
> Cc: Michael Ellerman <mpe@ellerman.id.au>
> Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
> Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: Jiri Slaby <jslaby@suse.com>
> Cc: Mark Brown <broonie@kernel.org>
> Cc: Thomas Gleixner <tglx@linutronix.de>
> Cc: Paolo Bonzini <pbonzini@redhat.com>
> Cc: "Radim Krčmář" <rkrcmar@redhat.com>
> Cc: Evgeniy Polyakov <zbr@ioremap.net>
> Cc: "H. Peter Anvin" <hpa@zytor.com>
> Cc: x86@kernel.org
> Cc: Henrik Austad <henrik@austad.us>
> Cc: Andrew Morton <akpm@linux-foundation.org>
> Cc: Ian Kent <raven@themaw.net>
> Cc: Jacek Anaszewski <jacek.anaszewski@gmail.com>
> Cc: Mike Rapoport <rppt@linux.vnet.ibm.com>
> Cc: Jan Kandziora <jjj@gmx.de>
> Cc: linux-doc@vger.kernel.org
> Cc: linux-kernel@vger.kernel.org
> Cc: linux-pci@vger.kernel.org
> Cc: devicetree@vger.kernel.org
> Cc: dri-devel@lists.freedesktop.org
> Cc: linux-fbdev@vger.kernel.org
> Cc: linux-gpio@vger.kernel.org
> Cc: linux-ide@vger.kernel.org
> Cc: netdev@vger.kernel.org
> Cc: linux-kbuild@vger.kernel.org
> Cc: linux-mips@linux-mips.org
> Cc: linux-security-module@vger.kernel.org
> Cc: linux-parisc@vger.kernel.org
> Cc: linux-pm@vger.kernel.org
> Cc: linuxppc-dev@lists.ozlabs.org
> Cc: linux-s390@vger.kernel.org
> Cc: linux-spi@vger.kernel.org
> Cc: kvm@vger.kernel.org
> Signed-off-by: Henrik Austad <haustad@cisco.com>
> ---
> Documentation/00-INDEX | 428 --------------------------------
> Documentation/PCI/00-INDEX | 26 --
> Documentation/RCU/00-INDEX | 34 ---
> Documentation/RCU/rcu.txt | 4 -
> Documentation/admin-guide/README.rst | 3 +-
> Documentation/arm/00-INDEX | 50 ----
> Documentation/block/00-INDEX | 34 ---
> Documentation/blockdev/00-INDEX | 18 --
> Documentation/cdrom/00-INDEX | 11 -
> Documentation/cgroup-v1/00-INDEX | 26 --
> Documentation/devicetree/00-INDEX | 12 -
> Documentation/fb/00-INDEX | 75 ------
> Documentation/filesystems/00-INDEX | 153 ------------
> Documentation/filesystems/nfs/00-INDEX | 26 --
> Documentation/fmc/00-INDEX | 38 ---
> Documentation/gpio/00-INDEX | 4 -
> Documentation/ide/00-INDEX | 14 --
> Documentation/ioctl/00-INDEX | 12 -
> Documentation/isdn/00-INDEX | 42 ----
> Documentation/kbuild/00-INDEX | 14 --
> Documentation/laptops/00-INDEX | 16 --
> Documentation/leds/00-INDEX | 32 ---
> Documentation/locking/00-INDEX | 16 --
> Documentation/m68k/00-INDEX | 7 -
> Documentation/mips/00-INDEX | 4 -
> Documentation/mmc/00-INDEX | 10 -
> Documentation/netlabel/00-INDEX | 10 -
> Documentation/netlabel/cipso_ipv4.txt | 11 +-
> Documentation/netlabel/introduction.txt | 2 +-
> Documentation/networking/00-INDEX | 234 -----------------
> Documentation/parisc/00-INDEX | 6 -
> Documentation/power/00-INDEX | 44 ----
> Documentation/powerpc/00-INDEX | 34 ---
> Documentation/s390/00-INDEX | 28 ---
> Documentation/scheduler/00-INDEX | 18 --
> Documentation/scsi/00-INDEX | 108 --------
> Documentation/serial/00-INDEX | 16 --
> Documentation/spi/00-INDEX | 16 --
> Documentation/sysctl/00-INDEX | 16 --
> Documentation/timers/00-INDEX | 16 --
> Documentation/virtual/00-INDEX | 11 -
> Documentation/virtual/kvm/00-INDEX | 35 ---
> Documentation/vm/00-INDEX | 50 ----
> Documentation/w1/00-INDEX | 10 -
> Documentation/w1/masters/00-INDEX | 12 -
> Documentation/w1/slaves/00-INDEX | 14 --
> Documentation/x86/00-INDEX | 20 --
> Documentation/x86/x86_64/00-INDEX | 16 --
> README | 1 -
> scripts/check_00index.sh | 67 -----
> 50 files changed, 8 insertions(+), 1896 deletions(-)
> delete mode 100644 Documentation/00-INDEX
> delete mode 100644 Documentation/PCI/00-INDEX
> delete mode 100644 Documentation/RCU/00-INDEX
> delete mode 100644 Documentation/arm/00-INDEX
> delete mode 100644 Documentation/block/00-INDEX
> delete mode 100644 Documentation/blockdev/00-INDEX
> delete mode 100644 Documentation/cdrom/00-INDEX
> delete mode 100644 Documentation/cgroup-v1/00-INDEX
> delete mode 100644 Documentation/devicetree/00-INDEX
> delete mode 100644 Documentation/fb/00-INDEX
> delete mode 100644 Documentation/filesystems/00-INDEX
> delete mode 100644 Documentation/filesystems/nfs/00-INDEX
> delete mode 100644 Documentation/fmc/00-INDEX
> delete mode 100644 Documentation/gpio/00-INDEX
> delete mode 100644 Documentation/ide/00-INDEX
> delete mode 100644 Documentation/ioctl/00-INDEX
> delete mode 100644 Documentation/isdn/00-INDEX
> delete mode 100644 Documentation/kbuild/00-INDEX
> delete mode 100644 Documentation/laptops/00-INDEX
> delete mode 100644 Documentation/leds/00-INDEX
> delete mode 100644 Documentation/locking/00-INDEX
> delete mode 100644 Documentation/m68k/00-INDEX
> delete mode 100644 Documentation/mips/00-INDEX
> delete mode 100644 Documentation/mmc/00-INDEX
> delete mode 100644 Documentation/netlabel/00-INDEX
> delete mode 100644 Documentation/networking/00-INDEX
> delete mode 100644 Documentation/parisc/00-INDEX
> delete mode 100644 Documentation/power/00-INDEX
> delete mode 100644 Documentation/powerpc/00-INDEX
> delete mode 100644 Documentation/s390/00-INDEX
> delete mode 100644 Documentation/scheduler/00-INDEX
> delete mode 100644 Documentation/scsi/00-INDEX
> delete mode 100644 Documentation/serial/00-INDEX
> delete mode 100644 Documentation/spi/00-INDEX
> delete mode 100644 Documentation/sysctl/00-INDEX
> delete mode 100644 Documentation/timers/00-INDEX
> delete mode 100644 Documentation/virtual/00-INDEX
> delete mode 100644 Documentation/virtual/kvm/00-INDEX
> delete mode 100644 Documentation/vm/00-INDEX
> delete mode 100644 Documentation/w1/00-INDEX
> delete mode 100644 Documentation/w1/masters/00-INDEX
> delete mode 100644 Documentation/w1/slaves/00-INDEX
> delete mode 100644 Documentation/x86/00-INDEX
> delete mode 100644 Documentation/x86/x86_64/00-INDEX
> delete mode 100755 scripts/check_00index.sh
>
> diff --git a/Documentation/00-INDEX b/Documentation/00-INDEX
> deleted file mode 100644
> index 2754fe8..0000000
> --- a/Documentation/00-INDEX
> +++ /dev/null
> @@ -1,428 +0,0 @@
> -
> -This is a brief list of all the files in ./linux/Documentation and what
> -they contain. If you add a documentation file, please list it here in
> -alphabetical order as well, or risk being hunted down like a rabid dog.
> -Please keep the descriptions small enough to fit on one line.
> - Thanks -- Paul G.
> -
> -Following translations are available on the WWW:
> -
> - - Japanese, maintained by the JF Project (jf@listserv.linux.or.jp), at
> - http://linuxjf.sourceforge.jp/
> -
> -00-INDEX
> - - this file.
> -ABI/
> - - info on kernel <-> userspace ABI and relative interface stability.
> -CodingStyle
> - - nothing here, just a pointer to process/coding-style.rst.
> -DMA-API.txt
> - - DMA API, pci_ API & extensions for non-consistent memory machines.
> -DMA-API-HOWTO.txt
> - - Dynamic DMA mapping Guide
> -DMA-ISA-LPC.txt
> - - How to do DMA with ISA (and LPC) devices.
> -DMA-attributes.txt
> - - listing of the various possible attributes a DMA region can have
> -EDID/
> - - directory with info on customizing EDID for broken gfx/displays.
> -IPMI.txt
> - - info on Linux Intelligent Platform Management Interface (IPMI) Driver.
> -IRQ-affinity.txt
> - - how to select which CPU(s) handle which interrupt events on SMP.
> -IRQ-domain.txt
> - - info on interrupt numbering and setting up IRQ domains.
> -IRQ.txt
> - - description of what an IRQ is.
> -Intel-IOMMU.txt
> - - basic info on the Intel IOMMU virtualization support.
> -Makefile
> - - It's not of interest for those who aren't touching the build system.
> -PCI/
> - - info related to PCI drivers.
> -RCU/
> - - directory with info on RCU (read-copy update).
> -SAK.txt
> - - info on Secure Attention Keys.
> -SM501.txt
> - - Silicon Motion SM501 multimedia companion chip
> -SubmittingPatches
> - - nothing here, just a pointer to process/coding-style.rst.
> -accounting/
> - - documentation on accounting and taskstats.
> -acpi/
> - - info on ACPI-specific hooks in the kernel.
> -admin-guide/
> - - info related to Linux users and system admins.
> -aoe/
> - - description of AoE (ATA over Ethernet) along with config examples.
> -arm/
> - - directory with info about Linux on the ARM architecture.
> -arm64/
> - - directory with info about Linux on the 64 bit ARM architecture.
> -auxdisplay/
> - - misc. LCD driver documentation (cfag12864b, ks0108).
> -backlight/
> - - directory with info on controlling backlights in flat panel displays
> -block/
> - - info on the Block I/O (BIO) layer.
> -blockdev/
> - - info on block devices & drivers
> -bt8xxgpio.txt
> - - info on how to modify a bt8xx video card for GPIO usage.
> -btmrvl.txt
> - - info on Marvell Bluetooth driver usage.
> -bus-devices/
> - - directory with info on TI GPMC (General Purpose Memory Controller)
> -bus-virt-phys-mapping.txt
> - - how to access I/O mapped memory from within device drivers.
> -cdrom/
> - - directory with information on the CD-ROM drivers that Linux has.
> -cgroup-v1/
> - - cgroups v1 features, including cpusets and memory controller.
> -cma/
> - - Continuous Memory Area (CMA) debugfs interface.
> -conf.py
> - - It's not of interest for those who aren't touching the build system.
> -connector/
> - - docs on the netlink based userspace<->kernel space communication mod.
> -console/
> - - documentation on Linux console drivers.
> -core-api/
> - - documentation on kernel core components.
> -cpu-freq/
> - - info on CPU frequency and voltage scaling.
> -cpu-hotplug.txt
> - - document describing CPU hotplug support in the Linux kernel.
> -cpu-load.txt
> - - document describing how CPU load statistics are collected.
> -cpuidle/
> - - info on CPU_IDLE, CPU idle state management subsystem.
> -cputopology.txt
> - - documentation on how CPU topology info is exported via sysfs.
> -crc32.txt
> - - brief tutorial on CRC computation
> -crypto/
> - - directory with info on the Crypto API.
> -dcdbas.txt
> - - information on the Dell Systems Management Base Driver.
> -debugging-modules.txt
> - - some notes on debugging modules after Linux 2.6.3.
> -debugging-via-ohci1394.txt
> - - how to use firewire like a hardware debugger memory reader.
> -dell_rbu.txt
> - - document demonstrating the use of the Dell Remote BIOS Update driver.
> -dev-tools/
> - - directory with info on development tools for the kernel.
> -device-mapper/
> - - directory with info on Device Mapper.
> -dmaengine/
> - - the DMA engine and controller API guides.
> -devicetree/
> - - directory with info on device tree files used by OF/PowerPC/ARM
> -digsig.txt
> - -info on the Digital Signature Verification API
> -dma-buf-sharing.txt
> - - the DMA Buffer Sharing API Guide
> -docutils.conf
> - - nothing here. Just a configuration file for docutils.
> -dontdiff
> - - file containing a list of files that should never be diff'ed.
> -driver-api/
> - - the Linux driver implementer's API guide.
> -driver-model/
> - - directory with info about Linux driver model.
> -early-userspace/
> - - info about initramfs, klibc, and userspace early during boot.
> -efi-stub.txt
> - - How to use the EFI boot stub to bypass GRUB or elilo on EFI systems.
> -eisa.txt
> - - info on EISA bus support.
> -extcon/
> - - directory with porting guide for Android kernel switch driver.
> -isa.txt
> - - info on EISA bus support.
> -fault-injection/
> - - dir with docs about the fault injection capabilities infrastructure.
> -fb/
> - - directory with info on the frame buffer graphics abstraction layer.
> -features/
> - - status of feature implementation on different architectures.
> -filesystems/
> - - info on the vfs and the various filesystems that Linux supports.
> -firmware_class/
> - - request_firmware() hotplug interface info.
> -flexible-arrays.txt
> - - how to make use of flexible sized arrays in linux
> -fmc/
> - - information about the FMC bus abstraction
> -fpga/
> - - FPGA Manager Core.
> -futex-requeue-pi.txt
> - - info on requeueing of tasks from a non-PI futex to a PI futex
> -gcc-plugins.txt
> - - GCC plugin infrastructure.
> -gpio/
> - - gpio related documentation
> -gpu/
> - - directory with information on GPU driver developer's guide.
> -hid/
> - - directory with information on human interface devices
> -highuid.txt
> - - notes on the change from 16 bit to 32 bit user/group IDs.
> -hwspinlock.txt
> - - hardware spinlock provides hardware assistance for synchronization
> -timers/
> - - info on the timer related topics
> -hw_random.txt
> - - info on Linux support for random number generator in i8xx chipsets.
> -hwmon/
> - - directory with docs on various hardware monitoring drivers.
> -i2c/
> - - directory with info about the I2C bus/protocol (2 wire, kHz speed).
> -x86/i386/
> - - directory with info about Linux on Intel 32 bit architecture.
> -ia64/
> - - directory with info about Linux on Intel 64 bit architecture.
> -ide/
> - - Information regarding the Enhanced IDE drive.
> -iio/
> - - info on industrial IIO configfs support.
> -index.rst
> - - main index for the documentation at ReST format.
> -infiniband/
> - - directory with documents concerning Linux InfiniBand support.
> -input/
> - - info on Linux input device support.
> -intel_txt.txt
> - - info on intel Trusted Execution Technology (intel TXT).
> -io-mapping.txt
> - - description of io_mapping functions in linux/io-mapping.h
> -io_ordering.txt
> - - info on ordering I/O writes to memory-mapped addresses.
> -ioctl/
> - - directory with documents describing various IOCTL calls.
> -iostats.txt
> - - info on I/O statistics Linux kernel provides.
> -irqflags-tracing.txt
> - - how to use the irq-flags tracing feature.
> -isapnp.txt
> - - info on Linux ISA Plug & Play support.
> -isdn/
> - - directory with info on the Linux ISDN support, and supported cards.
> -kbuild/
> - - directory with info about the kernel build process.
> -kdump/
> - - directory with mini HowTo on getting the crash dump code to work.
> -doc-guide/
> - - how to write and format reStructuredText kernel documentation
> -kernel-per-CPU-kthreads.txt
> - - List of all per-CPU kthreads and how they introduce jitter.
> -kobject.txt
> - - info of the kobject infrastructure of the Linux kernel.
> -kprobes.txt
> - - documents the kernel probes debugging feature.
> -kref.txt
> - - docs on adding reference counters (krefs) to kernel objects.
> -laptops/
> - - directory with laptop related info and laptop driver documentation.
> -ldm.txt
> - - a brief description of LDM (Windows Dynamic Disks).
> -leds/
> - - directory with info about LED handling under Linux.
> -livepatch/
> - - info on kernel live patching.
> -locking/
> - - directory with info about kernel locking primitives
> -lockup-watchdogs.txt
> - - info on soft and hard lockup detectors (aka nmi_watchdog).
> -logo.gif
> - - full colour GIF image of Linux logo (penguin - Tux).
> -logo.txt
> - - info on creator of above logo & site to get additional images from.
> -lsm.txt
> - - Linux Security Modules: General Security Hooks for Linux
> -lzo.txt
> - - kernel LZO decompressor input formats
> -m68k/
> - - directory with info about Linux on Motorola 68k architecture.
> -mailbox.txt
> - - How to write drivers for the common mailbox framework (IPC).
> -md/
> - - directory with info about Linux Software RAID
> -media/
> - - info on media drivers: uAPI, kAPI and driver documentation.
> -memory-barriers.txt
> - - info on Linux kernel memory barriers.
> -memory-devices/
> - - directory with info on parts like the Texas Instruments EMIF driver
> -memory-hotplug.txt
> - - Hotpluggable memory support, how to use and current status.
> -men-chameleon-bus.txt
> - - info on MEN chameleon bus.
> -mic/
> - - Intel Many Integrated Core (MIC) architecture device driver.
> -mips/
> - - directory with info about Linux on MIPS architecture.
> -misc-devices/
> - - directory with info about devices using the misc dev subsystem
> -mmc/
> - - directory with info about the MMC subsystem
> -mtd/
> - - directory with info about memory technology devices (flash)
> -namespaces/
> - - directory with various information about namespaces
> -netlabel/
> - - directory with information on the NetLabel subsystem.
> -networking/
> - - directory with info on various aspects of networking with Linux.
> -nfc/
> - - directory relating info about Near Field Communications support.
> -nios2/
> - - Linux on the Nios II architecture.
> -nommu-mmap.txt
> - - documentation about no-mmu memory mapping support.
> -numastat.txt
> - - info on how to read Numa policy hit/miss statistics in sysfs.
> -ntb.txt
> - - info on Non-Transparent Bridge (NTB) drivers.
> -nvdimm/
> - - info on non-volatile devices.
> -nvmem/
> - - info on non volatile memory framework.
> -output/
> - - default directory where html/LaTeX/pdf files will be written.
> -padata.txt
> - - An introduction to the "padata" parallel execution API
> -parisc/
> - - directory with info on using Linux on PA-RISC architecture.
> -parport-lowlevel.txt
> - - description and usage of the low level parallel port functions.
> -pcmcia/
> - - info on the Linux PCMCIA driver.
> -percpu-rw-semaphore.txt
> - - RCU based read-write semaphore optimized for locking for reading
> -perf/
> - - info about the APM X-Gene SoC Performance Monitoring Unit (PMU).
> -phy/
> - - ino on Samsung USB 2.0 PHY adaptation layer.
> -phy.txt
> - - Description of the generic PHY framework.
> -pi-futex.txt
> - - documentation on lightweight priority inheritance futexes.
> -pinctrl.txt
> - - info on pinctrl subsystem and the PINMUX/PINCONF and drivers
> -platform/
> - - List of supported hardware by compal and Dell laptop.
> -pnp.txt
> - - Linux Plug and Play documentation.
> -power/
> - - directory with info on Linux PCI power management.
> -powerpc/
> - - directory with info on using Linux with the PowerPC.
> -prctl/
> - - directory with info on the priveledge control subsystem
> -preempt-locking.txt
> - - info on locking under a preemptive kernel.
> -process/
> - - how to work with the mainline kernel development process.
> -pps/
> - - directory with information on the pulse-per-second support
> -pti/
> - - directory with info on Intel MID PTI.
> -ptp/
> - - directory with info on support for IEEE 1588 PTP clocks in Linux.
> -pwm.txt
> - - info on the pulse width modulation driver subsystem
> -rapidio/
> - - directory with info on RapidIO packet-based fabric interconnect
> -rbtree.txt
> - - info on what red-black trees are and what they are for.
> -remoteproc.txt
> - - info on how to handle remote processor (e.g. AMP) offloads/usage.
> -rfkill.txt
> - - info on the radio frequency kill switch subsystem/support.
> -robust-futex-ABI.txt
> - - documentation of the robust futex ABI.
> -robust-futexes.txt
> - - a description of what robust futexes are.
> -rpmsg.txt
> - - info on the Remote Processor Messaging (rpmsg) Framework
> -rtc.txt
> - - notes on how to use the Real Time Clock (aka CMOS clock) driver.
> -s390/
> - - directory with info on using Linux on the IBM S390.
> -scheduler/
> - - directory with info on the scheduler.
> -scsi/
> - - directory with info on Linux scsi support.
> -security/
> - - directory that contains security-related info
> -serial/
> - - directory with info on the low level serial API.
> -sgi-ioc4.txt
> - - description of the SGI IOC4 PCI (multi function) device.
> -sh/
> - - directory with info on porting Linux to a new architecture.
> -smsc_ece1099.txt
> - -info on the smsc Keyboard Scan Expansion/GPIO Expansion device.
> -sound/
> - - directory with info on sound card support.
> -spi/
> - - overview of Linux kernel Serial Peripheral Interface (SPI) support.
> -sphinx/
> - - no documentation here, just files required by Sphinx toolchain.
> -sphinx-static/
> - - no documentation here, just files required by Sphinx toolchain.
> -static-keys.txt
> - - info on how static keys allow debug code in hotpaths via patching
> -svga.txt
> - - short guide on selecting video modes at boot via VGA BIOS.
> -sync_file.txt
> - - Sync file API guide.
> -sysctl/
> - - directory with info on the /proc/sys/* files.
> -target/
> - - directory with info on generating TCM v4 fabric .ko modules
> -tee.txt
> - - info on the TEE subsystem and drivers
> -this_cpu_ops.txt
> - - List rationale behind and the way to use this_cpu operations.
> -thermal/
> - - directory with information on managing thermal issues (CPU/temp)
> -trace/
> - - directory with info on tracing technologies within linux
> -translations/
> - - translations of this document from English to another language
> -unaligned-memory-access.txt
> - - info on how to avoid arch breaking unaligned memory access in code.
> -unshare.txt
> - - description of the Linux unshare system call.
> -usb/
> - - directory with info regarding the Universal Serial Bus.
> -vfio.txt
> - - info on Virtual Function I/O used in guest/hypervisor instances.
> -video-output.txt
> - - sysfs class driver interface to enable/disable a video output device.
> -virtual/
> - - directory with information on the various linux virtualizations.
> -vm/
> - - directory with info on the Linux vm code.
> -w1/
> - - directory with documents regarding the 1-wire (w1) subsystem.
> -watchdog/
> - - how to auto-reboot Linux if it has "fallen and can't get up". ;-)
> -wimax/
> - - directory with info about Intel Wireless Wimax Connections
> -core-api/workqueue.rst
> - - information on the Concurrency Managed Workqueue implementation
> -x86/x86_64/
> - - directory with info on Linux support for AMD x86-64 (Hammer) machines.
> -xillybus.txt
> - - Overview and basic ui of xillybus driver
> -xtensa/
> - - directory with documents relating to arch/xtensa port/implementation
> -xz.txt
> - - how to make use of the XZ data compression within linux kernel
> -zorro.txt
> - - info on writing drivers for Zorro bus devices found on Amigas.
> diff --git a/Documentation/PCI/00-INDEX b/Documentation/PCI/00-INDEX
> deleted file mode 100644
> index 206b1d5..0000000
> --- a/Documentation/PCI/00-INDEX
> +++ /dev/null
> @@ -1,26 +0,0 @@
> -00-INDEX
> - - this file
> -acpi-info.txt
> - - info on how PCI host bridges are represented in ACPI
> -MSI-HOWTO.txt
> - - the Message Signaled Interrupts (MSI) Driver Guide HOWTO and FAQ.
> -PCIEBUS-HOWTO.txt
> - - a guide describing the PCI Express Port Bus driver
> -pci-error-recovery.txt
> - - info on PCI error recovery
> -pci-iov-howto.txt
> - - the PCI Express I/O Virtualization HOWTO
> -pci.txt
> - - info on the PCI subsystem for device driver authors
> -pcieaer-howto.txt
> - - the PCI Express Advanced Error Reporting Driver Guide HOWTO
> -endpoint/pci-endpoint.txt
> - - guide to add endpoint controller driver and endpoint function driver.
> -endpoint/pci-endpoint-cfs.txt
> - - guide to use configfs to configure the PCI endpoint function.
> -endpoint/pci-test-function.txt
> - - specification of *PCI test* function device.
> -endpoint/pci-test-howto.txt
> - - userguide for PCI endpoint test function.
> -endpoint/function/binding/
> - - binding documentation for PCI endpoint function
> diff --git a/Documentation/RCU/00-INDEX b/Documentation/RCU/00-INDEX
> deleted file mode 100644
> index f46980c..0000000
> --- a/Documentation/RCU/00-INDEX
> +++ /dev/null
> @@ -1,34 +0,0 @@
> -00-INDEX
> - - This file
> -arrayRCU.txt
> - - Using RCU to Protect Read-Mostly Arrays
> -checklist.txt
> - - Review Checklist for RCU Patches
> -listRCU.txt
> - - Using RCU to Protect Read-Mostly Linked Lists
> -lockdep.txt
> - - RCU and lockdep checking
> -lockdep-splat.txt
> - - RCU Lockdep splats explained.
> -NMI-RCU.txt
> - - Using RCU to Protect Dynamic NMI Handlers
> -rcu_dereference.txt
> - - Proper care and feeding of return values from rcu_dereference()
> -rcubarrier.txt
> - - RCU and Unloadable Modules
> -rculist_nulls.txt
> - - RCU list primitives for use with SLAB_TYPESAFE_BY_RCU
> -rcuref.txt
> - - Reference-count design for elements of lists/arrays protected by RCU
> -rcu.txt
> - - RCU Concepts
> -RTFP.txt
> - - List of RCU papers (bibliography) going back to 1980.
> -stallwarn.txt
> - - RCU CPU stall warnings (module parameter rcu_cpu_stall_suppress)
> -torture.txt
> - - RCU Torture Test Operation (CONFIG_RCU_TORTURE_TEST)
> -UP.txt
> - - RCU on Uniprocessor Systems
> -whatisRCU.txt
> - - What is RCU?
> diff --git a/Documentation/RCU/rcu.txt b/Documentation/RCU/rcu.txt
> index 7d4ae11..721b3e4 100644
> --- a/Documentation/RCU/rcu.txt
> +++ b/Documentation/RCU/rcu.txt
> @@ -87,7 +87,3 @@ o Where can I find more information on RCU?
>
> See the RTFP.txt file in this directory.
> Or point your browser at http://www.rdrop.com/users/paulmck/RCU/.
> -
> -o What are all these files in this directory?
> -
> - See 00-INDEX for the list.
> diff --git a/Documentation/admin-guide/README.rst b/Documentation/admin-guide/README.rst
> index 15ea785..0797eec 100644
> --- a/Documentation/admin-guide/README.rst
> +++ b/Documentation/admin-guide/README.rst
> @@ -51,8 +51,7 @@ Documentation
>
> - There are various README files in the Documentation/ subdirectory:
> these typically contain kernel-specific installation notes for some
> - drivers for example. See Documentation/00-INDEX for a list of what
> - is contained in each file. Please read the
> + drivers for example. Please read the
> :ref:`Documentation/process/changes.rst <changes>` file, as it
> contains information about the problems, which may result by upgrading
> your kernel.
> diff --git a/Documentation/arm/00-INDEX b/Documentation/arm/00-INDEX
> deleted file mode 100644
> index b6e69fd..0000000
> --- a/Documentation/arm/00-INDEX
> +++ /dev/null
> @@ -1,50 +0,0 @@
> -00-INDEX
> - - this file
> -Booting
> - - requirements for booting
> -CCN.txt
> - - Cache Coherent Network ring-bus and perf PMU driver.
> -Interrupts
> - - ARM Interrupt subsystem documentation
> -IXP4xx
> - - Intel IXP4xx Network processor.
> -Netwinder
> - - Netwinder specific documentation
> -Porting
> - - Symbol definitions for porting Linux to a new ARM machine.
> -Setup
> - - Kernel initialization parameters on ARM Linux
> -README
> - - General ARM documentation
> -SA1100/
> - - SA1100 documentation
> -Samsung-S3C24XX/
> - - S3C24XX ARM Linux Overview
> -SPEAr/
> - - ST SPEAr platform Linux Overview
> -VFP/
> - - Release notes for Linux Kernel Vector Floating Point support code
> -cluster-pm-race-avoidance.txt
> - - Algorithm for CPU and Cluster setup/teardown
> -empeg/
> - - Ltd's Empeg MP3 Car Audio Player
> -firmware.txt
> - - Secure firmware registration and calling.
> -kernel_mode_neon.txt
> - - How to use NEON instructions in kernel mode
> -kernel_user_helpers.txt
> - - Helper functions in kernel space made available for userspace.
> -mem_alignment
> - - alignment abort handler documentation
> -memory.txt
> - - description of the virtual memory layout
> -nwfpe/
> - - NWFPE floating point emulator documentation
> -swp_emulation
> - - SWP/SWPB emulation handler/logging description
> -tcm.txt
> - - ARM Tightly Coupled Memory
> -uefi.txt
> - - [U]EFI configuration and runtime services documentation
> -vlocks.txt
> - - Voting locks, low-level mechanism relying on memory system atomic writes.
> diff --git a/Documentation/block/00-INDEX b/Documentation/block/00-INDEX
> deleted file mode 100644
> index 8d55b4b..0000000
> --- a/Documentation/block/00-INDEX
> +++ /dev/null
> @@ -1,34 +0,0 @@
> -00-INDEX
> - - This file
> -bfq-iosched.txt
> - - BFQ IO scheduler and its tunables
> -biodoc.txt
> - - Notes on the Generic Block Layer Rewrite in Linux 2.5
> -biovecs.txt
> - - Immutable biovecs and biovec iterators
> -capability.txt
> - - Generic Block Device Capability (/sys/block/<device>/capability)
> -cfq-iosched.txt
> - - CFQ IO scheduler tunables
> -cmdline-partition.txt
> - - how to specify block device partitions on kernel command line
> -data-integrity.txt
> - - Block data integrity
> -deadline-iosched.txt
> - - Deadline IO scheduler tunables
> -ioprio.txt
> - - Block io priorities (in CFQ scheduler)
> -pr.txt
> - - Block layer support for Persistent Reservations
> -null_blk.txt
> - - Null block for block-layer benchmarking.
> -queue-sysfs.txt
> - - Queue's sysfs entries
> -request.txt
> - - The members of struct request (in include/linux/blkdev.h)
> -stat.txt
> - - Block layer statistics in /sys/block/<device>/stat
> -switching-sched.txt
> - - Switching I/O schedulers at runtime
> -writeback_cache_control.txt
> - - Control of volatile write back caches
> diff --git a/Documentation/blockdev/00-INDEX b/Documentation/blockdev/00-INDEX
> deleted file mode 100644
> index c08df56..0000000
> --- a/Documentation/blockdev/00-INDEX
> +++ /dev/null
> @@ -1,18 +0,0 @@
> -00-INDEX
> - - this file
> -README.DAC960
> - - info on Mylex DAC960/DAC1100 PCI RAID Controller Driver for Linux.
> -cciss.txt
> - - info, major/minor #'s for Compaq's SMART Array Controllers.
> -cpqarray.txt
> - - info on using Compaq's SMART2 Intelligent Disk Array Controllers.
> -floppy.txt
> - - notes and driver options for the floppy disk driver.
> -mflash.txt
> - - info on mGine m(g)flash driver for linux.
> -nbd.txt
> - - info on a TCP implementation of a network block device.
> -paride.txt
> - - information about the parallel port IDE subsystem.
> -ramdisk.txt
> - - short guide on how to set up and use the RAM disk.
> diff --git a/Documentation/cdrom/00-INDEX b/Documentation/cdrom/00-INDEX
> deleted file mode 100644
> index 433edf2..0000000
> --- a/Documentation/cdrom/00-INDEX
> +++ /dev/null
> @@ -1,11 +0,0 @@
> -00-INDEX
> - - this file (info on CD-ROMs and Linux)
> -Makefile
> - - only used to generate TeX output from the documentation.
> -cdrom-standard.tex
> - - LaTeX document on standardizing the CD-ROM programming interface.
> -ide-cd
> - - info on setting up and using ATAPI (aka IDE) CD-ROMs.
> -packet-writing.txt
> - - Info on the CDRW packet writing module
> -
> diff --git a/Documentation/cgroup-v1/00-INDEX b/Documentation/cgroup-v1/00-INDEX
> deleted file mode 100644
> index 13e0c85..0000000
> --- a/Documentation/cgroup-v1/00-INDEX
> +++ /dev/null
> @@ -1,26 +0,0 @@
> -00-INDEX
> - - this file
> -blkio-controller.txt
> - - Description for Block IO Controller, implementation and usage details.
> -cgroups.txt
> - - Control Groups definition, implementation details, examples and API.
> -cpuacct.txt
> - - CPU Accounting Controller; account CPU usage for groups of tasks.
> -cpusets.txt
> - - documents the cpusets feature; assign CPUs and Mem to a set of tasks.
> -admin-guide/devices.rst
> - - Device Whitelist Controller; description, interface and security.
> -freezer-subsystem.txt
> - - checkpointing; rationale to not use signals, interface.
> -hugetlb.txt
> - - HugeTLB Controller implementation and usage details.
> -memcg_test.txt
> - - Memory Resource Controller; implementation details.
> -memory.txt
> - - Memory Resource Controller; design, accounting, interface, testing.
> -net_cls.txt
> - - Network classifier cgroups details and usages.
> -net_prio.txt
> - - Network priority cgroups details and usages.
> -pids.txt
> - - Process number cgroups details and usages.
> diff --git a/Documentation/devicetree/00-INDEX b/Documentation/devicetree/00-INDEX
> deleted file mode 100644
> index 8c4102c..0000000
> --- a/Documentation/devicetree/00-INDEX
> +++ /dev/null
> @@ -1,12 +0,0 @@
> -Documentation for device trees, a data structure by which bootloaders pass
> -hardware layout to Linux in a device-independent manner, simplifying hardware
> -probing. This subsystem is maintained by Grant Likely
> -<grant.likely@secretlab.ca> and has a mailing list at
> -https://lists.ozlabs.org/listinfo/devicetree-discuss
> -
> -00-INDEX
> - - this file
> -booting-without-of.txt
> - - Booting Linux without Open Firmware, describes history and format of device trees.
> -usage-model.txt
> - - How Linux uses DT and what DT aims to solve.
> \ No newline at end of file
> diff --git a/Documentation/fb/00-INDEX b/Documentation/fb/00-INDEX
> deleted file mode 100644
> index fe85e7c..0000000
> --- a/Documentation/fb/00-INDEX
> +++ /dev/null
> @@ -1,75 +0,0 @@
> -Index of files in Documentation/fb. If you think something about frame
> -buffer devices needs an entry here, needs correction or you've written one
> -please mail me.
> - Geert Uytterhoeven <geert@linux-m68k.org>
> -
> -00-INDEX
> - - this file.
> -api.txt
> - - The frame buffer API between applications and buffer devices.
> -arkfb.txt
> - - info on the fbdev driver for ARK Logic chips.
> -aty128fb.txt
> - - info on the ATI Rage128 frame buffer driver.
> -cirrusfb.txt
> - - info on the driver for Cirrus Logic chipsets.
> -cmap_xfbdev.txt
> - - an introduction to fbdev's cmap structures.
> -deferred_io.txt
> - - an introduction to deferred IO.
> -efifb.txt
> - - info on the EFI platform driver for Intel based Apple computers.
> -ep93xx-fb.txt
> - - info on the driver for EP93xx LCD controller.
> -fbcon.txt
> - - intro to and usage guide for the framebuffer console (fbcon).
> -framebuffer.txt
> - - introduction to frame buffer devices.
> -gxfb.txt
> - - info on the framebuffer driver for AMD Geode GX2 based processors.
> -intel810.txt
> - - documentation for the Intel 810/815 framebuffer driver.
> -intelfb.txt
> - - docs for Intel 830M/845G/852GM/855GM/865G/915G/945G fb driver.
> -internals.txt
> - - quick overview of frame buffer device internals.
> -lxfb.txt
> - - info on the framebuffer driver for AMD Geode LX based processors.
> -matroxfb.txt
> - - info on the Matrox framebuffer driver for Alpha, Intel and PPC.
> -metronomefb.txt
> - - info on the driver for the Metronome display controller.
> -modedb.txt
> - - info on the video mode database.
> -pvr2fb.txt
> - - info on the PowerVR 2 frame buffer driver.
> -pxafb.txt
> - - info on the driver for the PXA25x LCD controller.
> -s3fb.txt
> - - info on the fbdev driver for S3 Trio/Virge chips.
> -sa1100fb.txt
> - - information about the driver for the SA-1100 LCD controller.
> -sh7760fb.txt
> - - info on the SH7760/SH7763 integrated LCDC Framebuffer driver.
> -sisfb.txt
> - - info on the framebuffer device driver for various SiS chips.
> -sm501.txt
> - - info on the framebuffer device driver for sm501 videoframebuffer.
> -sstfb.txt
> - - info on the frame buffer driver for 3dfx' Voodoo Graphics boards.
> -tgafb.txt
> - - info on the TGA (DECChip 21030) frame buffer driver.
> -tridentfb.txt
> - info on the framebuffer driver for some Trident chip based cards.
> -udlfb.txt
> - - Driver for DisplayLink USB 2.0 chips.
> -uvesafb.txt
> - - info on the userspace VESA (VBE2+ compliant) frame buffer device.
> -vesafb.txt
> - - info on the VESA frame buffer device.
> -viafb.modes
> - - list of modes for VIA Integration Graphic Chip.
> -viafb.txt
> - - info on the VIA Integration Graphic Chip console framebuffer driver.
> -vt8623fb.txt
> - - info on the fb driver for the graphics core in VIA VT8623 chipsets.
> diff --git a/Documentation/filesystems/00-INDEX b/Documentation/filesystems/00-INDEX
> deleted file mode 100644
> index 0937bad..0000000
> --- a/Documentation/filesystems/00-INDEX
> +++ /dev/null
> @@ -1,153 +0,0 @@
> -00-INDEX
> - - this file (info on some of the filesystems supported by linux).
> -Locking
> - - info on locking rules as they pertain to Linux VFS.
> -9p.txt
> - - 9p (v9fs) is an implementation of the Plan 9 remote fs protocol.
> -adfs.txt
> - - info and mount options for the Acorn Advanced Disc Filing System.
> -afs.txt
> - - info and examples for the distributed AFS (Andrew File System) fs.
> -affs.txt
> - - info and mount options for the Amiga Fast File System.
> -autofs-mount-control.txt
> - - info on device control operations for autofs module.
> -automount-support.txt
> - - information about filesystem automount support.
> -befs.txt
> - - information about the BeOS filesystem for Linux.
> -bfs.txt
> - - info for the SCO UnixWare Boot Filesystem (BFS).
> -btrfs.txt
> - - info for the BTRFS filesystem.
> -caching/
> - - directory containing filesystem cache documentation.
> -ceph.txt
> - - info for the Ceph Distributed File System.
> -cifs/
> - - directory containing CIFS filesystem documentation and example code.
> -coda.txt
> - - description of the CODA filesystem.
> -configfs/
> - - directory containing configfs documentation and example code.
> -cramfs.txt
> - - info on the cram filesystem for small storage (ROMs etc).
> -dax.txt
> - - info on avoiding the page cache for files stored on CPU-addressable
> - storage devices.
> -debugfs.txt
> - - info on the debugfs filesystem.
> -devpts.txt
> - - info on the devpts filesystem.
> -directory-locking
> - - info about the locking scheme used for directory operations.
> -dlmfs.txt
> - - info on the userspace interface to the OCFS2 DLM.
> -dnotify.txt
> - - info about directory notification in Linux.
> -dnotify_test.c
> - - example program for dnotify.
> -ecryptfs.txt
> - - docs on eCryptfs: stacked cryptographic filesystem for Linux.
> -efivarfs.txt
> - - info for the efivarfs filesystem.
> -exofs.txt
> - - info, usage, mount options, design about EXOFS.
> -ext2.txt
> - - info, mount options and specifications for the Ext2 filesystem.
> -ext3.txt
> - - info, mount options and specifications for the Ext3 filesystem.
> -ext4.txt
> - - info, mount options and specifications for the Ext4 filesystem.
> -f2fs.txt
> - - info and mount options for the F2FS filesystem.
> -fiemap.txt
> - - info on fiemap ioctl.
> -files.txt
> - - info on file management in the Linux kernel.
> -fuse.txt
> - - info on the Filesystem in User SpacE including mount options.
> -gfs2-glocks.txt
> - - info on the Global File System 2 - Glock internal locking rules.
> -gfs2-uevents.txt
> - - info on the Global File System 2 - uevents.
> -gfs2.txt
> - - info on the Global File System 2.
> -hfs.txt
> - - info on the Macintosh HFS Filesystem for Linux.
> -hfsplus.txt
> - - info on the Macintosh HFSPlus Filesystem for Linux.
> -hpfs.txt
> - - info and mount options for the OS/2 HPFS.
> -inotify.txt
> - - info on the powerful yet simple file change notification system.
> -isofs.txt
> - - info and mount options for the ISO 9660 (CDROM) filesystem.
> -jfs.txt
> - - info and mount options for the JFS filesystem.
> -locks.txt
> - - info on file locking implementations, flock() vs. fcntl(), etc.
> -mandatory-locking.txt
> - - info on the Linux implementation of Sys V mandatory file locking.
> -nfs/
> - - nfs-related documentation.
> -nilfs2.txt
> - - info and mount options for the NILFS2 filesystem.
> -ntfs.txt
> - - info and mount options for the NTFS filesystem (Windows NT).
> -ocfs2.txt
> - - info and mount options for the OCFS2 clustered filesystem.
> -omfs.txt
> - - info on the Optimized MPEG FileSystem.
> -path-lookup.txt
> - - info on path walking and name lookup locking.
> -pohmelfs/
> - - directory containing pohmelfs filesystem documentation.
> -porting
> - - various information on filesystem porting.
> -proc.txt
> - - info on Linux's /proc filesystem.
> -qnx6.txt
> - - info on the QNX6 filesystem.
> -quota.txt
> - - info on Quota subsystem.
> -ramfs-rootfs-initramfs.txt
> - - info on the 'in memory' filesystems ramfs, rootfs and initramfs.
> -relay.txt
> - - info on relay, for efficient streaming from kernel to user space.
> -romfs.txt
> - - description of the ROMFS filesystem.
> -seq_file.txt
> - - how to use the seq_file API.
> -sharedsubtree.txt
> - - a description of shared subtrees for namespaces.
> -spufs.txt
> - - info and mount options for the SPU filesystem used on Cell.
> -squashfs.txt
> - - info on the squashfs filesystem.
> -sysfs-pci.txt
> - - info on accessing PCI device resources through sysfs.
> -sysfs-tagging.txt
> - - info on sysfs tagging to avoid duplicates.
> -sysfs.txt
> - - info on sysfs, a ram-based filesystem for exporting kernel objects.
> -sysv-fs.txt
> - - info on the SystemV/V7/Xenix/Coherent filesystem.
> -tmpfs.txt
> - - info on tmpfs, a filesystem that holds all files in virtual memory.
> -ubifs.txt
> - - info on the Unsorted Block Images FileSystem.
> -udf.txt
> - - info and mount options for the UDF filesystem.
> -ufs.txt
> - - info on the ufs filesystem.
> -vfat.txt
> - - info on using the VFAT filesystem used in Windows NT and Windows 95.
> -vfs.txt
> - - overview of the Virtual File System.
> -xfs-delayed-logging-design.txt
> - - info on the XFS Delayed Logging Design.
> -xfs-self-describing-metadata.txt
> - - info on XFS Self Describing Metadata.
> -xfs.txt
> - - info and mount options for the XFS filesystem.
> diff --git a/Documentation/filesystems/nfs/00-INDEX b/Documentation/filesystems/nfs/00-INDEX
> deleted file mode 100644
> index 53f3b59..0000000
> --- a/Documentation/filesystems/nfs/00-INDEX
> +++ /dev/null
> @@ -1,26 +0,0 @@
> -00-INDEX
> - - this file (nfs-related documentation).
> -Exporting
> - - explanation of how to make filesystems exportable.
> -fault_injection.txt
> - - information for using fault injection on the server
> -knfsd-stats.txt
> - - statistics which the NFS server makes available to user space.
> -nfs.txt
> - - nfs client, and DNS resolution for fs_locations.
> -nfs41-server.txt
> - - info on the Linux server implementation of NFSv4 minor version 1.
> -nfs-rdma.txt
> - - how to install and setup the Linux NFS/RDMA client and server software
> -nfsd-admin-interfaces.txt
> - - Administrative interfaces for nfsd.
> -nfsroot.txt
> - - short guide on setting up a diskless box with NFS root filesystem.
> -pnfs.txt
> - - short explanation of some of the internals of the pnfs client code
> -rpc-cache.txt
> - - introduction to the caching mechanisms in the sunrpc layer.
> -idmapper.txt
> - - information for configuring request-keys to be used by idmapper
> -rpc-server-gss.txt
> - - Information on GSS authentication support in the NFS Server
> diff --git a/Documentation/fmc/00-INDEX b/Documentation/fmc/00-INDEX
> deleted file mode 100644
> index 431c695..0000000
> --- a/Documentation/fmc/00-INDEX
> +++ /dev/null
> @@ -1,38 +0,0 @@
> -
> -Documentation in this directory comes from sections of the manual we
> -wrote for the externally-developed fmc-bus package. The complete
> -manual as of today (2013-02) is available in PDF format at
> -http://www.ohwr.org/projects/fmc-bus/files
> -
> -00-INDEX
> - - this file.
> -
> -FMC-and-SDB.txt
> - - What are FMC and SDB, basic concepts for this framework
> -
> -API.txt
> - - The functions that are exported by the bus driver
> -
> -parameters.txt
> - - The module parameters
> -
> -carrier.txt
> - - writing a carrier (a device)
> -
> -mezzanine.txt
> - - writing code for your mezzanine (a driver)
> -
> -identifiers.txt
> - - how identification and matching works
> -
> -fmc-fakedev.txt
> - - about drivers/fmc/fmc-fakedev.ko
> -
> -fmc-trivial.txt
> - - about drivers/fmc/fmc-trivial.ko
> -
> -fmc-write-eeprom.txt
> - - about drivers/fmc/fmc-write-eeprom.ko
> -
> -fmc-chardev.txt
> - - about drivers/fmc/fmc-chardev.ko
> diff --git a/Documentation/gpio/00-INDEX b/Documentation/gpio/00-INDEX
> deleted file mode 100644
> index 17e19a6..0000000
> --- a/Documentation/gpio/00-INDEX
> +++ /dev/null
> @@ -1,4 +0,0 @@
> -00-INDEX
> - - This file
> -sysfs.txt
> - - Information about the GPIO sysfs interface
> diff --git a/Documentation/ide/00-INDEX b/Documentation/ide/00-INDEX
> deleted file mode 100644
> index 22f98ca..0000000
> --- a/Documentation/ide/00-INDEX
> +++ /dev/null
> @@ -1,14 +0,0 @@
> -00-INDEX
> - - this file
> -ChangeLog.ide-cd.1994-2004
> - - ide-cd changelog
> -ChangeLog.ide-floppy.1996-2002
> - - ide-floppy changelog
> -ChangeLog.ide-tape.1995-2002
> - - ide-tape changelog
> -ide-tape.txt
> - - info on the IDE ATAPI streaming tape driver
> -ide.txt
> - - important info for users of ATA devices (IDE/EIDE disks and CD-ROMS).
> -warm-plug-howto.txt
> - - using sysfs to remove and add IDE devices.
> \ No newline at end of file
> diff --git a/Documentation/ioctl/00-INDEX b/Documentation/ioctl/00-INDEX
> deleted file mode 100644
> index c1a9257..0000000
> --- a/Documentation/ioctl/00-INDEX
> +++ /dev/null
> @@ -1,12 +0,0 @@
> -00-INDEX
> - - this file
> -botching-up-ioctls.txt
> - - how to avoid botching up ioctls
> -cdrom.txt
> - - summary of CDROM ioctl calls
> -hdio.txt
> - - summary of HDIO_ ioctl calls
> -ioctl-decoding.txt
> - - how to decode the bits of an IOCTL code
> -ioctl-number.txt
> - - how to implement and register device/driver ioctl calls
> diff --git a/Documentation/isdn/00-INDEX b/Documentation/isdn/00-INDEX
> deleted file mode 100644
> index 2d1889b..0000000
> --- a/Documentation/isdn/00-INDEX
> +++ /dev/null
> @@ -1,42 +0,0 @@
> -00-INDEX
> - - this file (info on ISDN implementation for Linux)
> -CREDITS
> - - list of the kind folks that brought you this stuff.
> -HiSax.cert
> - - information about the ITU approval certification of the HiSax driver.
> -INTERFACE
> - - description of isdn4linux Link Level and Hardware Level interfaces.
> -INTERFACE.fax
> - - description of the fax subinterface of isdn4linux.
> -INTERFACE.CAPI
> - - description of kernel CAPI Link Level to Hardware Level interface.
> -README
> - - general info on what you need and what to do for Linux ISDN.
> -README.FAQ
> - - general info for FAQ.
> -README.HiSax
> - - info on the HiSax driver which replaces the old teles.
> -README.audio
> - - info for running audio over ISDN.
> -README.avmb1
> - - info on driver for AVM-B1 ISDN card.
> -README.concap
> - - info on "CONCAP" encapsulation protocol interface used for X.25.
> -README.diversion
> - - info on module for isdn diversion services.
> -README.fax
> - - info for using Fax over ISDN.
> -README.gigaset
> - - info on the drivers for Siemens Gigaset ISDN adapters
> -README.hfc-pci
> - - info on hfc-pci based cards.
> -README.hysdn
> - - info on driver for Hypercope active HYSDN cards
> -README.mISDN
> - - info on the Modular ISDN subsystem (mISDN)
> -README.syncppp
> - - info on running Sync PPP over ISDN.
> -README.x25
> - - info for running X.25 over ISDN.
> -syncPPP.FAQ
> - - frequently asked questions about running PPP over ISDN.
> diff --git a/Documentation/kbuild/00-INDEX b/Documentation/kbuild/00-INDEX
> deleted file mode 100644
> index 8c5e6aa..0000000
> --- a/Documentation/kbuild/00-INDEX
> +++ /dev/null
> @@ -1,14 +0,0 @@
> -00-INDEX
> - - this file: info on the kernel build process
> -headers_install.txt
> - - how to export Linux headers for use by userspace
> -kbuild.txt
> - - developer information on kbuild
> -kconfig.txt
> - - usage help for make *config
> -kconfig-language.txt
> - - specification of Config Language, the language in Kconfig files
> -makefiles.txt
> - - developer information for linux kernel makefiles
> -modules.txt
> - - how to build modules and to install them
> diff --git a/Documentation/laptops/00-INDEX b/Documentation/laptops/00-INDEX
> deleted file mode 100644
> index 86169dc..0000000
> --- a/Documentation/laptops/00-INDEX
> +++ /dev/null
> @@ -1,16 +0,0 @@
> -00-INDEX
> - - This file
> -asus-laptop.txt
> - - information on the Asus Laptop Extras driver.
> -disk-shock-protection.txt
> - - information on hard disk shock protection.
> -laptop-mode.txt
> - - how to conserve battery power using laptop-mode.
> -sony-laptop.txt
> - - Sony Notebook Control Driver (SNC) Readme.
> -sonypi.txt
> - - info on Linux Sony Programmable I/O Device support.
> -thinkpad-acpi.txt
> - - information on the (IBM and Lenovo) ThinkPad ACPI Extras driver.
> -toshiba_haps.txt
> - - information on the Toshiba HDD Active Protection Sensor driver.
> diff --git a/Documentation/leds/00-INDEX b/Documentation/leds/00-INDEX
> deleted file mode 100644
> index ae626b2..0000000
> --- a/Documentation/leds/00-INDEX
> +++ /dev/null
> @@ -1,32 +0,0 @@
> -00-INDEX
> - - This file
> -leds-blinkm.txt
> - - Driver for BlinkM LED-devices.
> -leds-class.txt
> - - documents LED handling under Linux.
> -leds-class-flash.txt
> - - documents flash LED handling under Linux.
> -leds-lm3556.txt
> - - notes on how to use the leds-lm3556 driver.
> -leds-lp3944.txt
> - - notes on how to use the leds-lp3944 driver.
> -leds-lp5521.txt
> - - notes on how to use the leds-lp5521 driver.
> -leds-lp5523.txt
> - - notes on how to use the leds-lp5523 driver.
> -leds-lp5562.txt
> - - notes on how to use the leds-lp5562 driver.
> -leds-lp55xx.txt
> - - description about lp55xx common driver.
> -leds-lm3556.txt
> - - notes on how to use the leds-lm3556 driver.
> -leds-mlxcpld.txt
> - - notes on how to use the leds-mlxcpld driver.
> -ledtrig-oneshot.txt
> - - One-shot LED trigger for both sporadic and dense events.
> -ledtrig-transient.txt
> - - LED Transient Trigger, one shot timer activation.
> -ledtrig-usbport.txt
> - - notes on how to use the drivers/usb/core/ledtrig-usbport.c trigger.
> -uleds.txt
> - - notes on how to use the uleds driver.
> diff --git a/Documentation/locking/00-INDEX b/Documentation/locking/00-INDEX
> deleted file mode 100644
> index c256c9b..0000000
> --- a/Documentation/locking/00-INDEX
> +++ /dev/null
> @@ -1,16 +0,0 @@
> -00-INDEX
> - - this file.
> -lockdep-design.txt
> - - documentation on the runtime locking correctness validator.
> -lockstat.txt
> - - info on collecting statistics on locks (and contention).
> -mutex-design.txt
> - - info on the generic mutex subsystem.
> -rt-mutex-design.txt
> - - description of the RealTime mutex implementation design.
> -rt-mutex.txt
> - - desc. of RT-mutex subsystem with PI (Priority Inheritance) support.
> -spinlocks.txt
> - - info on using spinlocks to provide exclusive access in kernel.
> -ww-mutex-design.txt
> - - Intro to Mutex wait/would deadlock handling.s
> diff --git a/Documentation/m68k/00-INDEX b/Documentation/m68k/00-INDEX
> deleted file mode 100644
> index 2be8c6b..0000000
> --- a/Documentation/m68k/00-INDEX
> +++ /dev/null
> @@ -1,7 +0,0 @@
> -00-INDEX
> - - this file
> -README.buddha
> - - Amiga Buddha and Catweasel IDE Driver
> -kernel-options.txt
> - - command line options for Linux/m68k
> -
> diff --git a/Documentation/mips/00-INDEX b/Documentation/mips/00-INDEX
> deleted file mode 100644
> index 8ae9cff..0000000
> --- a/Documentation/mips/00-INDEX
> +++ /dev/null
> @@ -1,4 +0,0 @@
> -00-INDEX
> - - this file.
> -AU1xxx_IDE.README
> - - README for MIPS AU1XXX IDE driver.
> diff --git a/Documentation/mmc/00-INDEX b/Documentation/mmc/00-INDEX
> deleted file mode 100644
> index 4623bc0..0000000
> --- a/Documentation/mmc/00-INDEX
> +++ /dev/null
> @@ -1,10 +0,0 @@
> -00-INDEX
> - - this file
> -mmc-dev-attrs.txt
> - - info on SD and MMC device attributes
> -mmc-dev-parts.txt
> - - info on SD and MMC device partitions
> -mmc-async-req.txt
> - - info on mmc asynchronous requests
> -mmc-tools.txt
> - - info on mmc-utils tools
> diff --git a/Documentation/netlabel/00-INDEX b/Documentation/netlabel/00-INDEX
> deleted file mode 100644
> index 837bf35..0000000
> --- a/Documentation/netlabel/00-INDEX
> +++ /dev/null
> @@ -1,10 +0,0 @@
> -00-INDEX
> - - this file.
> -cipso_ipv4.txt
> - - documentation on the IPv4 CIPSO protocol engine.
> -draft-ietf-cipso-ipsecurity-01.txt
> - - IETF draft of the CIPSO protocol, dated 16 July 1992.
> -introduction.txt
> - - NetLabel introduction, READ THIS FIRST.
> -lsm_interface.txt
> - - documentation on the NetLabel kernel security module API.
> diff --git a/Documentation/netlabel/cipso_ipv4.txt b/Documentation/netlabel/cipso_ipv4.txt
> index 93dacb1..a607548 100644
> --- a/Documentation/netlabel/cipso_ipv4.txt
> +++ b/Documentation/netlabel/cipso_ipv4.txt
> @@ -6,11 +6,12 @@ May 17, 2006
>
> * Overview
>
> -The NetLabel CIPSO/IPv4 protocol engine is based on the IETF Commercial IP
> -Security Option (CIPSO) draft from July 16, 1992. A copy of this draft can be
> -found in this directory, consult '00-INDEX' for the filename. While the IETF
> -draft never made it to an RFC standard it has become a de-facto standard for
> -labeled networking and is used in many trusted operating systems.
> +The NetLabel CIPSO/IPv4 protocol engine is based on the IETF Commercial
> +IP Security Option (CIPSO) draft from July 16, 1992. A copy of this
> +draft can be found in this directory
> +(draft-ietf-cipso-ipsecurity-01.txt). While the IETF draft never made
> +it to an RFC standard it has become a de-facto standard for labeled
> +networking and is used in many trusted operating systems.
>
> * Outbound Packet Processing
>
> diff --git a/Documentation/netlabel/introduction.txt b/Documentation/netlabel/introduction.txt
> index 5ecd8d1..3caf77b 100644
> --- a/Documentation/netlabel/introduction.txt
> +++ b/Documentation/netlabel/introduction.txt
> @@ -22,7 +22,7 @@ refrain from calling the protocol engines directly, instead they should use
> the NetLabel kernel security module API described below.
>
> Detailed information about each NetLabel protocol engine can be found in this
> -directory, consult '00-INDEX' for filenames.
> +directory.
>
> * Communication Layer
>
> diff --git a/Documentation/networking/00-INDEX b/Documentation/networking/00-INDEX
> deleted file mode 100644
> index 02a323c..0000000
> --- a/Documentation/networking/00-INDEX
> +++ /dev/null
> @@ -1,234 +0,0 @@
> -00-INDEX
> - - this file
> -3c509.txt
> - - information on the 3Com Etherlink III Series Ethernet cards.
> -6pack.txt
> - - info on the 6pack protocol, an alternative to KISS for AX.25
> -LICENSE.qla3xxx
> - - GPLv2 for QLogic Linux Networking HBA Driver
> -LICENSE.qlge
> - - GPLv2 for QLogic Linux qlge NIC Driver
> -LICENSE.qlcnic
> - - GPLv2 for QLogic Linux qlcnic NIC Driver
> -PLIP.txt
> - - PLIP: The Parallel Line Internet Protocol device driver
> -README.ipw2100
> - - README for the Intel PRO/Wireless 2100 driver.
> -README.ipw2200
> - - README for the Intel PRO/Wireless 2915ABG and 2200BG driver.
> -README.sb1000
> - - info on General Instrument/NextLevel SURFboard1000 cable modem.
> -altera_tse.txt
> - - Altera Triple-Speed Ethernet controller.
> -arcnet-hardware.txt
> - - tons of info on ARCnet, hubs, jumper settings for ARCnet cards, etc.
> -arcnet.txt
> - - info on the using the ARCnet driver itself.
> -atm.txt
> - - info on where to get ATM programs and support for Linux.
> -ax25.txt
> - - info on using AX.25 and NET/ROM code for Linux
> -baycom.txt
> - - info on the driver for Baycom style amateur radio modems
> -bonding.txt
> - - Linux Ethernet Bonding Driver HOWTO: link aggregation in Linux.
> -bridge.txt
> - - where to get user space programs for ethernet bridging with Linux.
> -cdc_mbim.txt
> - - 3G/LTE USB modem (Mobile Broadband Interface Model)
> -checksum-offloads.txt
> - - Explanation of checksum offloads; LCO, RCO
> -cops.txt
> - - info on the COPS LocalTalk Linux driver
> -cs89x0.txt
> - - the Crystal LAN (CS8900/20-based) Ethernet ISA adapter driver
> -cxacru.txt
> - - Conexant AccessRunner USB ADSL Modem
> -cxacru-cf.py
> - - Conexant AccessRunner USB ADSL Modem configuration file parser
> -cxgb.txt
> - - Release Notes for the Chelsio N210 Linux device driver.
> -dccp.txt
> - - the Datagram Congestion Control Protocol (DCCP) (RFC 4340..42).
> -dctcp.txt
> - - DataCenter TCP congestion control
> -de4x5.txt
> - - the Digital EtherWORKS DE4?? and DE5?? PCI Ethernet driver
> -decnet.txt
> - - info on using the DECnet networking layer in Linux.
> -dl2k.txt
> - - README for D-Link DL2000-based Gigabit Ethernet Adapters (dl2k.ko).
> -dm9000.txt
> - - README for the Simtec DM9000 Network driver.
> -dmfe.txt
> - - info on the Davicom DM9102(A)/DM9132/DM9801 fast ethernet driver.
> -dns_resolver.txt
> - - The DNS resolver module allows kernel servies to make DNS queries.
> -driver.txt
> - - Softnet driver issues.
> -ena.txt
> - - info on Amazon's Elastic Network Adapter (ENA)
> -e100.txt
> - - info on Intel's EtherExpress PRO/100 line of 10/100 boards
> -e1000.txt
> - - info on Intel's E1000 line of gigabit ethernet boards
> -e1000e.txt
> - - README for the Intel Gigabit Ethernet Driver (e1000e).
> -eql.txt
> - - serial IP load balancing
> -fib_trie.txt
> - - Level Compressed Trie (LC-trie) notes: a structure for routing.
> -filter.txt
> - - Linux Socket Filtering
> -fore200e.txt
> - - FORE Systems PCA-200E/SBA-200E ATM NIC driver info.
> -framerelay.txt
> - - info on using Frame Relay/Data Link Connection Identifier (DLCI).
> -gen_stats.txt
> - - Generic networking statistics for netlink users.
> -generic-hdlc.txt
> - - The generic High Level Data Link Control (HDLC) layer.
> -generic_netlink.txt
> - - info on Generic Netlink
> -gianfar.txt
> - - Gianfar Ethernet Driver.
> -i40e.txt
> - - README for the Intel Ethernet Controller XL710 Driver (i40e).
> -i40evf.txt
> - - Short note on the Driver for the Intel(R) XL710 X710 Virtual Function
> -ieee802154.txt
> - - Linux IEEE 802.15.4 implementation, API and drivers
> -igb.txt
> - - README for the Intel Gigabit Ethernet Driver (igb).
> -igbvf.txt
> - - README for the Intel Gigabit Ethernet Driver (igbvf).
> -ip-sysctl.txt
> - - /proc/sys/net/ipv4/* variables
> -ip_dynaddr.txt
> - - IP dynamic address hack e.g. for auto-dialup links
> -ipddp.txt
> - - AppleTalk-IP Decapsulation and AppleTalk-IP Encapsulation
> -iphase.txt
> - - Interphase PCI ATM (i)Chip IA Linux driver info.
> -ipsec.txt
> - - Note on not compressing IPSec payload and resulting failed policy check.
> -ipv6.txt
> - - Options to the ipv6 kernel module.
> -ipvs-sysctl.txt
> - - Per-inode explanation of the /proc/sys/net/ipv4/vs interface.
> -irda.txt
> - - where to get IrDA (infrared) utilities and info for Linux.
> -ixgb.txt
> - - README for the Intel 10 Gigabit Ethernet Driver (ixgb).
> -ixgbe.txt
> - - README for the Intel 10 Gigabit Ethernet Driver (ixgbe).
> -ixgbevf.txt
> - - README for the Intel Virtual Function (VF) Driver (ixgbevf).
> -l2tp.txt
> - - User guide to the L2TP tunnel protocol.
> -lapb-module.txt
> - - programming information of the LAPB module.
> -ltpc.txt
> - - the Apple or Farallon LocalTalk PC card driver
> -mac80211-auth-assoc-deauth.txt
> - - authentication and association / deauth-disassoc with max80211
> -mac80211-injection.txt
> - - HOWTO use packet injection with mac80211
> -multiqueue.txt
> - - HOWTO for multiqueue network device support.
> -netconsole.txt
> - - The network console module netconsole.ko: configuration and notes.
> -netdev-features.txt
> - - Network interface features API description.
> -netdevices.txt
> - - info on network device driver functions exported to the kernel.
> -netif-msg.txt
> - - Design of the network interface message level setting (NETIF_MSG_*).
> -netlink_mmap.txt
> - - memory mapped I/O with netlink
> -nf_conntrack-sysctl.txt
> - - list of netfilter-sysctl knobs.
> -nfc.txt
> - - The Linux Near Field Communication (NFS) subsystem.
> -openvswitch.txt
> - - Open vSwitch developer documentation.
> -operstates.txt
> - - Overview of network interface operational states.
> -packet_mmap.txt
> - - User guide to memory mapped packet socket rings (PACKET_[RT]X_RING).
> -phonet.txt
> - - The Phonet packet protocol used in Nokia cellular modems.
> -phy.txt
> - - The PHY abstraction layer.
> -pktgen.txt
> - - User guide to the kernel packet generator (pktgen.ko).
> -policy-routing.txt
> - - IP policy-based routing
> -ppp_generic.txt
> - - Information about the generic PPP driver.
> -proc_net_tcp.txt
> - - Per inode overview of the /proc/net/tcp and /proc/net/tcp6 interfaces.
> -radiotap-headers.txt
> - - Background on radiotap headers.
> -ray_cs.txt
> - - Raylink Wireless LAN card driver info.
> -rds.txt
> - - Background on the reliable, ordered datagram delivery method RDS.
> -regulatory.txt
> - - Overview of the Linux wireless regulatory infrastructure.
> -rxrpc.txt
> - - Guide to the RxRPC protocol.
> -s2io.txt
> - - Release notes for Neterion Xframe I/II 10GbE driver.
> -scaling.txt
> - - Explanation of network scaling techniques: RSS, RPS, RFS, aRFS, XPS.
> -sctp.txt
> - - Notes on the Linux kernel implementation of the SCTP protocol.
> -secid.txt
> - - Explanation of the secid member in flow structures.
> -skfp.txt
> - - SysKonnect FDDI (SK-5xxx, Compaq Netelligent) driver info.
> -smc9.txt
> - - the driver for SMC's 9000 series of Ethernet cards
> -spider_net.txt
> - - README for the Spidernet Driver (as found in PS3 / Cell BE).
> -stmmac.txt
> - - README for the STMicro Synopsys Ethernet driver.
> -tc-actions-env-rules.txt
> - - rules for traffic control (tc) actions.
> -timestamping.txt
> - - overview of network packet timestamping variants.
> -tcp.txt
> - - short blurb on how TCP output takes place.
> -tcp-thin.txt
> - - kernel tuning options for low rate 'thin' TCP streams.
> -team.txt
> - - pointer to information for ethernet teaming devices.
> -tlan.txt
> - - ThunderLAN (Compaq Netelligent 10/100, Olicom OC-2xxx) driver info.
> -tproxy.txt
> - - Transparent proxy support user guide.
> -tuntap.txt
> - - TUN/TAP device driver, allowing user space Rx/Tx of packets.
> -udplite.txt
> - - UDP-Lite protocol (RFC 3828) introduction.
> -vortex.txt
> - - info on using 3Com Vortex (3c590, 3c592, 3c595, 3c597) Ethernet cards.
> -vxge.txt
> - - README for the Neterion X3100 PCIe Server Adapter.
> -vxlan.txt
> - - Virtual extensible LAN overview
> -x25.txt
> - - general info on X.25 development.
> -x25-iface.txt
> - - description of the X.25 Packet Layer to LAPB device interface.
> -xfrm_device.txt
> - - description of XFRM offload API
> -xfrm_proc.txt
> - - description of the statistics package for XFRM.
> -xfrm_sync.txt
> - - sync patches for XFRM enable migration of an SA between hosts.
> -xfrm_sysctl.txt
> - - description of the XFRM configuration options.
> -z8530drv.txt
> - - info about Linux driver for Z8530 based HDLC cards for AX.25
> diff --git a/Documentation/parisc/00-INDEX b/Documentation/parisc/00-INDEX
> deleted file mode 100644
> index cbd0609..0000000
> --- a/Documentation/parisc/00-INDEX
> +++ /dev/null
> @@ -1,6 +0,0 @@
> -00-INDEX
> - - this file.
> -debugging
> - - some debugging hints for real-mode code
> -registers
> - - current/planned usage of registers
> diff --git a/Documentation/power/00-INDEX b/Documentation/power/00-INDEX
> deleted file mode 100644
> index 7f3c2de..0000000
> --- a/Documentation/power/00-INDEX
> +++ /dev/null
> @@ -1,44 +0,0 @@
> -00-INDEX
> - - This file
> -apm-acpi.txt
> - - basic info about the APM and ACPI support.
> -basic-pm-debugging.txt
> - - Debugging suspend and resume
> -charger-manager.txt
> - - Battery charger management.
> -admin-guide/devices.rst
> - - How drivers interact with system-wide power management
> -drivers-testing.txt
> - - Testing suspend and resume support in device drivers
> -freezing-of-tasks.txt
> - - How processes and controlled during suspend
> -interface.txt
> - - Power management user interface in /sys/power
> -opp.txt
> - - Operating Performance Point library
> -pci.txt
> - - How the PCI Subsystem Does Power Management
> -pm_qos_interface.txt
> - - info on Linux PM Quality of Service interface
> -power_supply_class.txt
> - - Tells userspace about battery, UPS, AC or DC power supply properties
> -runtime_pm.txt
> - - Power management framework for I/O devices.
> -s2ram.txt
> - - How to get suspend to ram working (and debug it when it isn't)
> -states.txt
> - - System power management states
> -suspend-and-cpuhotplug.txt
> - - Explains the interaction between Suspend-to-RAM (S3) and CPU hotplug
> -swsusp-and-swap-files.txt
> - - Using swap files with software suspend (to disk)
> -swsusp-dmcrypt.txt
> - - How to use dm-crypt and software suspend (to disk) together
> -swsusp.txt
> - - Goals, implementation, and usage of software suspend (ACPI S3)
> -tricks.txt
> - - How to trick software suspend (to disk) into working when it isn't
> -userland-swsusp.txt
> - - Experimental implementation of software suspend in userspace
> -video.txt
> - - Video issues during resume from suspend
> diff --git a/Documentation/powerpc/00-INDEX b/Documentation/powerpc/00-INDEX
> deleted file mode 100644
> index 9dc845c..0000000
> --- a/Documentation/powerpc/00-INDEX
> +++ /dev/null
> @@ -1,34 +0,0 @@
> -Index of files in Documentation/powerpc. If you think something about
> -Linux/PPC needs an entry here, needs correction or you've written one
> -please mail me.
> - Cort Dougan (cort@fsmlabs.com)
> -
> -00-INDEX
> - - this file
> -bootwrapper.txt
> - - Information on how the powerpc kernel is wrapped for boot on various
> - different platforms.
> -cpu_features.txt
> - - info on how we support a variety of CPUs with minimal compile-time
> - options.
> -cxl.txt
> - - Overview of the CXL driver.
> -eeh-pci-error-recovery.txt
> - - info on PCI Bus EEH Error Recovery
> -firmware-assisted-dump.txt
> - - Documentation on the firmware assisted dump mechanism "fadump".
> -hvcs.txt
> - - IBM "Hypervisor Virtual Console Server" Installation Guide
> -mpc52xx.txt
> - - Linux 2.6.x on MPC52xx family
> -pmu-ebb.txt
> - - Description of the API for using the PMU with Event Based Branches.
> -qe_firmware.txt
> - - describes the layout of firmware binaries for the Freescale QUICC
> - Engine and the code that parses and uploads the microcode therein.
> -ptrace.txt
> - - Information on the ptrace interfaces for hardware debug registers.
> -transactional_memory.txt
> - - Overview of the Power8 transactional memory support.
> -dscr.txt
> - - Overview DSCR (Data Stream Control Register) support.
> diff --git a/Documentation/s390/00-INDEX b/Documentation/s390/00-INDEX
> deleted file mode 100644
> index 317f037..0000000
> --- a/Documentation/s390/00-INDEX
> +++ /dev/null
> @@ -1,28 +0,0 @@
> -00-INDEX
> - - this file.
> -3270.ChangeLog
> - - ChangeLog for the UTS Global 3270-support patch (outdated).
> -3270.txt
> - - how to use the IBM 3270 display system support.
> -cds.txt
> - - s390 common device support (common I/O layer).
> -CommonIO
> - - common I/O layer command line parameters, procfs and debugfs entries
> -config3270.sh
> - - example configuration for 3270 devices.
> -DASD
> - - information on the DASD disk device driver.
> -Debugging390.txt
> - - hints for debugging on s390 systems.
> -driver-model.txt
> - - information on s390 devices and the driver model.
> -monreader.txt
> - - information on accessing the z/VM monitor stream from Linux.
> -qeth.txt
> - - HiperSockets Bridge Port Support.
> -s390dbf.txt
> - - information on using the s390 debug feature.
> -vfio-ccw.txt
> - information on the vfio-ccw I/O subchannel driver.
> -zfcpdump.txt
> - - information on the s390 SCSI dump tool.
> diff --git a/Documentation/scheduler/00-INDEX b/Documentation/scheduler/00-INDEX
> deleted file mode 100644
> index eccf7ad..0000000
> --- a/Documentation/scheduler/00-INDEX
> +++ /dev/null
> @@ -1,18 +0,0 @@
> -00-INDEX
> - - this file.
> -sched-arch.txt
> - - CPU Scheduler implementation hints for architecture specific code.
> -sched-bwc.txt
> - - CFS bandwidth control overview.
> -sched-design-CFS.txt
> - - goals, design and implementation of the Completely Fair Scheduler.
> -sched-domains.txt
> - - information on scheduling domains.
> -sched-nice-design.txt
> - - How and why the scheduler's nice levels are implemented.
> -sched-rt-group.txt
> - - real-time group scheduling.
> -sched-deadline.txt
> - - deadline scheduling.
> -sched-stats.txt
> - - information on schedstats (Linux Scheduler Statistics).
> diff --git a/Documentation/scsi/00-INDEX b/Documentation/scsi/00-INDEX
> deleted file mode 100644
> index bb4a76f..0000000
> --- a/Documentation/scsi/00-INDEX
> +++ /dev/null
> @@ -1,108 +0,0 @@
> -00-INDEX
> - - this file
> -53c700.txt
> - - info on driver for 53c700 based adapters
> -BusLogic.txt
> - - info on driver for adapters with BusLogic chips
> -ChangeLog.1992-1997
> - - Changes to scsi files, if not listed elsewhere
> -ChangeLog.arcmsr
> - - Changes to driver for ARECA's SATA RAID controller cards
> -ChangeLog.ips
> - - IBM ServeRAID driver Changelog
> -ChangeLog.lpfc
> - - Changes to lpfc driver
> -ChangeLog.megaraid
> - - Changes to LSI megaraid controller.
> -ChangeLog.megaraid_sas
> - - Changes to serial attached scsi version of LSI megaraid controller.
> -ChangeLog.ncr53c8xx
> - - Changes to ncr53c8xx driver
> -ChangeLog.sym53c8xx
> - - Changes to sym53c8xx driver
> -ChangeLog.sym53c8xx_2
> - - Changes to second generation of sym53c8xx driver
> -FlashPoint.txt
> - - info on driver for BusLogic FlashPoint adapters
> -LICENSE.FlashPoint
> - - Licence of the Flashpoint driver
> -LICENSE.qla2xxx
> - - License for QLogic Linux Fibre Channel HBA Driver firmware.
> -LICENSE.qla4xxx
> - - License for QLogic Linux iSCSI HBA Driver.
> -Mylex.txt
> - - info on driver for Mylex adapters
> -NinjaSCSI.txt
> - - info on WorkBiT NinjaSCSI-32/32Bi driver
> -aacraid.txt
> - - Driver supporting Adaptec RAID controllers
> -advansys.txt
> - - List of Advansys Host Adapters
> -aha152x.txt
> - - info on driver for Adaptec AHA152x based adapters
> -aic79xx.txt
> - - Adaptec Ultra320 SCSI host adapters
> -aic7xxx.txt
> - - info on driver for Adaptec controllers
> -arcmsr_spec.txt
> - - ARECA FIRMWARE SPEC (for IOP331 adapter)
> -bfa.txt
> - - Brocade FC/FCOE adapter driver.
> -bnx2fc.txt
> - - FCoE hardware offload for Broadcom network interfaces.
> -cxgb3i.txt
> - - Chelsio iSCSI Linux Driver
> -dc395x.txt
> - - README file for the dc395x SCSI driver
> -dpti.txt
> - - info on driver for DPT SmartRAID and Adaptec I2O RAID based adapters
> -dtc3x80.txt
> - - info on driver for DTC 2x80 based adapters
> -g_NCR5380.txt
> - - info on driver for NCR5380 and NCR53c400 based adapters
> -hpsa.txt
> - - HP Smart Array Controller SCSI driver.
> -hptiop.txt
> - - HIGHPOINT ROCKETRAID 3xxx RAID DRIVER
> -libsas.txt
> - - Serial Attached SCSI management layer.
> -link_power_management_policy.txt
> - - Link power management options.
> -lpfc.txt
> - - LPFC driver release notes
> -megaraid.txt
> - - Common Management Module, shared code handling ioctls for LSI drivers
> -ncr53c8xx.txt
> - - info on driver for NCR53c8xx based adapters
> -osd.txt
> - Object-Based Storage Device, command set introduction.
> -osst.txt
> - - info on driver for OnStream SC-x0 SCSI tape
> -ppa.txt
> - - info on driver for IOmega zip drive
> -qlogicfas.txt
> - - info on driver for QLogic FASxxx based adapters
> -scsi-changer.txt
> - - README for the SCSI media changer driver
> -scsi-generic.txt
> - - info on the sg driver for generic (non-disk/CD/tape) SCSI devices.
> -scsi-parameters.txt
> - - List of SCSI-parameters to pass to the kernel at module load-time.
> -scsi.txt
> - - short blurb on using SCSI support as a module.
> -scsi_mid_low_api.txt
> - - info on API between SCSI layer and low level drivers
> -scsi_eh.txt
> - - info on SCSI midlayer error handling infrastructure
> -scsi_fc_transport.txt
> - - SCSI Fiber Channel Tansport
> -st.txt
> - - info on scsi tape driver
> -sym53c500_cs.txt
> - - info on PCMCIA driver for Symbios Logic 53c500 based adapters
> -sym53c8xx_2.txt
> - - info on second generation driver for sym53c8xx based adapters
> -tmscsim.txt
> - - info on driver for AM53c974 based adapters
> -ufs.txt
> - - info on Universal Flash Storage(UFS) and UFS host controller driver.
> diff --git a/Documentation/serial/00-INDEX b/Documentation/serial/00-INDEX
> deleted file mode 100644
> index 8021a9f..0000000
> --- a/Documentation/serial/00-INDEX
> +++ /dev/null
> @@ -1,16 +0,0 @@
> -00-INDEX
> - - this file.
> -README.cycladesZ
> - - info on Cyclades-Z firmware loading.
> -driver
> - - intro to the low level serial driver.
> -moxa-smartio
> - - file with info on installing/using Moxa multiport serial driver.
> -n_gsm.txt
> - - GSM 0710 tty multiplexer howto.
> -rocket.txt
> - - info on the Comtrol RocketPort multiport serial driver.
> -serial-rs485.txt
> - - info about RS485 structures and support in the kernel.
> -tty.txt
> - - guide to the locking policies of the tty layer.
> diff --git a/Documentation/spi/00-INDEX b/Documentation/spi/00-INDEX
> deleted file mode 100644
> index 8e4bb17..0000000
> --- a/Documentation/spi/00-INDEX
> +++ /dev/null
> @@ -1,16 +0,0 @@
> -00-INDEX
> - - this file.
> -butterfly
> - - AVR Butterfly SPI driver overview and pin configuration.
> -ep93xx_spi
> - - Basic EP93xx SPI driver configuration.
> -pxa2xx
> - - PXA2xx SPI master controller build by spi_message fifo wq
> -spidev
> - - Intro to the userspace API for spi devices
> -spi-lm70llp
> - - Connecting an LM70-LLP sensor to the kernel via the SPI subsys.
> -spi-sc18is602
> - - NXP SC18IS602/603 I2C-bus to SPI bridge
> -spi-summary
> - - (Linux) SPI overview. If unsure about SPI or SPI in Linux, start here.
> diff --git a/Documentation/sysctl/00-INDEX b/Documentation/sysctl/00-INDEX
> deleted file mode 100644
> index 8cf5d49..0000000
> --- a/Documentation/sysctl/00-INDEX
> +++ /dev/null
> @@ -1,16 +0,0 @@
> -00-INDEX
> - - this file.
> -README
> - - general information about /proc/sys/ sysctl files.
> -abi.txt
> - - documentation for /proc/sys/abi/*.
> -fs.txt
> - - documentation for /proc/sys/fs/*.
> -kernel.txt
> - - documentation for /proc/sys/kernel/*.
> -net.txt
> - - documentation for /proc/sys/net/*.
> -sunrpc.txt
> - - documentation for /proc/sys/sunrpc/*.
> -vm.txt
> - - documentation for /proc/sys/vm/*.
> diff --git a/Documentation/timers/00-INDEX b/Documentation/timers/00-INDEX
> deleted file mode 100644
> index 3be05fe..0000000
> --- a/Documentation/timers/00-INDEX
> +++ /dev/null
> @@ -1,16 +0,0 @@
> -00-INDEX
> - - this file
> -highres.txt
> - - High resolution timers and dynamic ticks design notes
> -hpet.txt
> - - High Precision Event Timer Driver for Linux
> -hrtimers.txt
> - - subsystem for high-resolution kernel timers
> -NO_HZ.txt
> - - Summary of the different methods for the scheduler clock-interrupts management.
> -timekeeping.txt
> - - Clock sources, clock events, sched_clock() and delay timer notes
> -timers-howto.txt
> - - how to insert delays in the kernel the right (tm) way.
> -timer_stats.txt
> - - timer usage statistics
> diff --git a/Documentation/virtual/00-INDEX b/Documentation/virtual/00-INDEX
> deleted file mode 100644
> index af0d239..0000000
> --- a/Documentation/virtual/00-INDEX
> +++ /dev/null
> @@ -1,11 +0,0 @@
> -Virtualization support in the Linux kernel.
> -
> -00-INDEX
> - - this file.
> -
> -paravirt_ops.txt
> - - Describes the Linux kernel pv_ops to support different hypervisors
> -kvm/
> - - Kernel Virtual Machine. See also http://linux-kvm.org
> -uml/
> - - User Mode Linux, builds/runs Linux kernel as a userspace program.
> diff --git a/Documentation/virtual/kvm/00-INDEX b/Documentation/virtual/kvm/00-INDEX
> deleted file mode 100644
> index 3492458..0000000
> --- a/Documentation/virtual/kvm/00-INDEX
> +++ /dev/null
> @@ -1,35 +0,0 @@
> -00-INDEX
> - - this file.
> -amd-memory-encryption.rst
> - - notes on AMD Secure Encrypted Virtualization feature and SEV firmware
> - command description
> -api.txt
> - - KVM userspace API.
> -arm
> - - internal ABI between the kernel and HYP (for arm/arm64)
> -cpuid.txt
> - - KVM-specific cpuid leaves (x86).
> -devices/
> - - KVM_CAP_DEVICE_CTRL userspace API.
> -halt-polling.txt
> - - notes on halt-polling
> -hypercalls.txt
> - - KVM hypercalls.
> -locking.txt
> - - notes on KVM locks.
> -mmu.txt
> - - the x86 kvm shadow mmu.
> -msr.txt
> - - KVM-specific MSRs (x86).
> -nested-vmx.txt
> - - notes on nested virtualization for Intel x86 processors.
> -ppc-pv.txt
> - - the paravirtualization interface on PowerPC.
> -review-checklist.txt
> - - review checklist for KVM patches.
> -s390-diag.txt
> - - Diagnose hypercall description (for IBM S/390)
> -timekeeping.txt
> - - timekeeping virtualization for x86-based architectures.
> -vcpu-requests.rst
> - - internal VCPU request API
> diff --git a/Documentation/vm/00-INDEX b/Documentation/vm/00-INDEX
> deleted file mode 100644
> index f4a4f3e..0000000
> --- a/Documentation/vm/00-INDEX
> +++ /dev/null
> @@ -1,50 +0,0 @@
> -00-INDEX
> - - this file.
> -active_mm.rst
> - - An explanation from Linus about tsk->active_mm vs tsk->mm.
> -balance.rst
> - - various information on memory balancing.
> -cleancache.rst
> - - Intro to cleancache and page-granularity victim cache.
> -frontswap.rst
> - - Outline frontswap, part of the transcendent memory frontend.
> -highmem.rst
> - - Outline of highmem and common issues.
> -hmm.rst
> - - Documentation of heterogeneous memory management
> -hugetlbfs_reserv.rst
> - - A brief overview of hugetlbfs reservation design/implementation.
> -hwpoison.rst
> - - explains what hwpoison is
> -ksm.rst
> - - how to use the Kernel Samepage Merging feature.
> -mmu_notifier.rst
> - - a note about clearing pte/pmd and mmu notifications
> -numa.rst
> - - information about NUMA specific code in the Linux vm.
> -overcommit-accounting.rst
> - - description of the Linux kernels overcommit handling modes.
> -page_frags.rst
> - - description of page fragments allocator
> -page_migration.rst
> - - description of page migration in NUMA systems.
> -page_owner.rst
> - - tracking about who allocated each page
> -remap_file_pages.rst
> - - a note about remap_file_pages() system call
> -slub.rst
> - - a short users guide for SLUB.
> -split_page_table_lock.rst
> - - Separate per-table lock to improve scalability of the old page_table_lock.
> -swap_numa.rst
> - - automatic binding of swap device to numa node
> -transhuge.rst
> - - Transparent Hugepage Support, alternative way of using hugepages.
> -unevictable-lru.rst
> - - Unevictable LRU infrastructure
> -z3fold.txt
> - - outline of z3fold allocator for storing compressed pages
> -zsmalloc.rst
> - - outline of zsmalloc allocator for storing compressed pages
> -zswap.rst
> - - Intro to compressed cache for swap pages
> diff --git a/Documentation/w1/00-INDEX b/Documentation/w1/00-INDEX
> deleted file mode 100644
> index cb49802..0000000
> --- a/Documentation/w1/00-INDEX
> +++ /dev/null
> @@ -1,10 +0,0 @@
> -00-INDEX
> - - This file
> -slaves/
> - - Drivers that provide support for specific family codes.
> -masters/
> - - Individual chips providing 1-wire busses.
> -w1.generic
> - - The 1-wire (w1) bus
> -w1.netlink
> - - Userspace communication protocol over connector [1].
> diff --git a/Documentation/w1/masters/00-INDEX b/Documentation/w1/masters/00-INDEX
> deleted file mode 100644
> index 8330cf9..0000000
> --- a/Documentation/w1/masters/00-INDEX
> +++ /dev/null
> @@ -1,12 +0,0 @@
> -00-INDEX
> - - This file
> -ds2482
> - - The Maxim/Dallas Semiconductor DS2482 provides 1-wire busses.
> -ds2490
> - - The Maxim/Dallas Semiconductor DS2490 builds USB <-> W1 bridges.
> -mxc-w1
> - - W1 master controller driver found on Freescale MX2/MX3 SoCs
> -omap-hdq
> - - HDQ/1-wire module of TI OMAP 2430/3430.
> -w1-gpio
> - - GPIO 1-wire bus master driver.
> diff --git a/Documentation/w1/slaves/00-INDEX b/Documentation/w1/slaves/00-INDEX
> deleted file mode 100644
> index 68946f8..0000000
> --- a/Documentation/w1/slaves/00-INDEX
> +++ /dev/null
> @@ -1,14 +0,0 @@
> -00-INDEX
> - - This file
> -w1_therm
> - - The Maxim/Dallas Semiconductor ds18*20 temperature sensor.
> -w1_ds2413
> - - The Maxim/Dallas Semiconductor ds2413 dual channel addressable switch.
> -w1_ds2423
> - - The Maxim/Dallas Semiconductor ds2423 counter device.
> -w1_ds2438
> - - The Maxim/Dallas Semiconductor ds2438 smart battery monitor.
> -w1_ds28e04
> - - The Maxim/Dallas Semiconductor ds28e04 eeprom.
> -w1_ds28e17
> - - The Maxim/Dallas Semiconductor ds28e17 1-Wire-to-I2C Master Bridge.
> diff --git a/Documentation/x86/00-INDEX b/Documentation/x86/00-INDEX
> deleted file mode 100644
> index 3bb2ee3..0000000
> --- a/Documentation/x86/00-INDEX
> +++ /dev/null
> @@ -1,20 +0,0 @@
> -00-INDEX
> - - this file
> -boot.txt
> - - List of boot protocol versions
> -earlyprintk.txt
> - - Using earlyprintk with a USB2 debug port key.
> -entry_64.txt
> - - Describe (some of the) kernel entry points for x86.
> -exception-tables.txt
> - - why and how Linux kernel uses exception tables on x86
> -microcode.txt
> - - How to load microcode from an initrd-CPIO archive early to fix CPU issues.
> -mtrr.txt
> - - how to use x86 Memory Type Range Registers to increase performance
> -pat.txt
> - - Page Attribute Table intro and API
> -usb-legacy-support.txt
> - - how to fix/avoid quirks when using emulated PS/2 mouse/keyboard.
> -zero-page.txt
> - - layout of the first page of memory.
> diff --git a/Documentation/x86/x86_64/00-INDEX b/Documentation/x86/x86_64/00-INDEX
> deleted file mode 100644
> index 92fc20a..0000000
> --- a/Documentation/x86/x86_64/00-INDEX
> +++ /dev/null
> @@ -1,16 +0,0 @@
> -00-INDEX
> - - This file
> -boot-options.txt
> - - AMD64-specific boot options.
> -cpu-hotplug-spec
> - - Firmware support for CPU hotplug under Linux/x86-64
> -fake-numa-for-cpusets
> - - Using numa=fake and CPUSets for Resource Management
> -kernel-stacks
> - - Context-specific per-processor interrupt stacks.
> -machinecheck
> - - Configurable sysfs parameters for the x86-64 machine check code.
> -mm.txt
> - - Memory layout of x86-64 (4 level page tables, 46 bits physical).
> -uefi.txt
> - - Booting Linux via Unified Extensible Firmware Interface.
> diff --git a/README b/README
> index 2c927cc..669ac7c 100644
> --- a/README
> +++ b/README
> @@ -12,7 +12,6 @@ In order to build the documentation, use ``make htmldocs`` or
>
> There are various text files in the Documentation/ subdirectory,
> several of them using the Restructured Text markup notation.
> -See Documentation/00-INDEX for a list of what is contained in each file.
>
> Please read the Documentation/process/changes.rst file, as it contains the
> requirements for building and running the kernel, and information about
> diff --git a/scripts/check_00index.sh b/scripts/check_00index.sh
> deleted file mode 100755
> index aa47f592..0000000
> --- a/scripts/check_00index.sh
> +++ /dev/null
> @@ -1,67 +0,0 @@
> -#!/bin/bash
> -# SPDX-License-Identifier: GPL-2.0
> -
> -cd Documentation/
> -
> -# Check entries that should be removed
> -
> -obsolete=""
> -for i in $(tail -n +12 00-INDEX |grep -E '^[a-zA-Z0-9]+'); do
> - if [ ! -e $i ]; then
> - obsolete="$obsolete $i"
> - fi
> -done
> -
> -# Check directory entries that should be added
> -search=""
> -dir=""
> -for i in $(find . -maxdepth 1 -type d); do
> - if [ "$i" != "." ]; then
> - new=$(echo $i|perl -ne 's,./(.*),$1/,; print $_')
> - search="$search $new"
> - fi
> -done
> -
> -for i in $search; do
> - if [ "$(grep -P "^$i" 00-INDEX)" == "" ]; then
> - dir="$dir $i"
> - fi
> -done
> -
> -# Check file entries that should be added
> -search=""
> -file=""
> -for i in $(find . -maxdepth 1 -type f); do
> - if [ "$i" != "./.gitignore" ]; then
> - new=$(echo $i|perl -ne 's,./(.*),$1,; print $_')
> - search="$search $new"
> - fi
> -done
> -
> -for i in $search; do
> - if [ "$(grep -P "^$i\$" 00-INDEX)" == "" ]; then
> - file="$file $i"
> - fi
> -done
> -
> -# Output its findings
> -
> -echo -e "Documentation/00-INDEX check results:\n"
> -
> -if [ "$obsolete" != "" ]; then
> - echo -e "- Should remove those entries:\n\t$obsolete\n"
> -else
> - echo -e "- No obsolete entries\n"
> -fi
> -
> -if [ "$dir" != "" ]; then
> - echo -e "- Should document those directories:\n\t$dir\n"
> -else
> - echo -e "- No new directories to add\n"
> -fi
> -
> -if [ "$file" != "" ]; then
> - echo -e "- Should document those files:\n\t$file"
> -else
> - echo "- No new files to add"
> -fi
> --
> 2.7.4
>
--
Sincerely yours,
Mike.
^ permalink raw reply
* Re: [PATCH net-next v2 1/7] net: phy: mscc: factorize code for LEDs mode
From: Quentin Schulz @ 2018-09-04 17:56 UTC (permalink / raw)
To: David Miller
Cc: robh+dt, mark.rutland, andrew, f.fainelli, allan.nielsen, netdev,
devicetree, linux-kernel, thomas.petazzoni
In-Reply-To: <20180904.104827.447303663667237271.davem@davemloft.net>
[-- Attachment #1: Type: text/plain, Size: 611 bytes --]
Hi David,
On Tue, Sep 04, 2018 at 10:48:27AM -0700, David Miller wrote:
> From: Quentin Schulz <quentin.schulz@bootlin.com>
> Date: Mon, 3 Sep 2018 10:48:47 +0200
>
> > LEDs modes are set the same way, except they are offset by 4 times the
> > index of the LED.
> >
> > Let's factorize all the code so that it's easier to add support for the
> > 4 LEDs of the VSC8584 PHY.
> >
> > Signed-off-by: Quentin Schulz <quentin.schulz@bootlin.com>
>
> Entire series applied to net-next.
>
Thanks!
> Please provide a proper "0/N ..." cover letter next time.
>
Sure, will do.
Quentin
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply
* Re: [PATCH v2 00/11] mscc: ocelot: add support for SerDes muxing configuration
From: Quentin Schulz @ 2018-09-04 18:00 UTC (permalink / raw)
To: Paul Burton
Cc: Alexandre Belloni, David Miller, andrew, ralf, jhogan, robh+dt,
mark.rutland, kishon, f.fainelli, allan.nielsen, linux-mips,
devicetree, linux-kernel, netdev, thomas.petazzoni
In-Reply-To: <20180904161028.nh5ejrtj22r5az5e@pburton-laptop>
[-- Attachment #1: Type: text/plain, Size: 1896 bytes --]
Hi Paul,
On Tue, Sep 04, 2018 at 09:10:28AM -0700, Paul Burton wrote:
> Hi Alexandre, Quentin, all,
>
> On Tue, Sep 04, 2018 at 05:16:53PM +0200, Alexandre Belloni wrote:
> > On 03/09/2018 22:09:10-0700, David Miller wrote:
> > > From: Alexandre Belloni <alexandre.belloni@bootlin.com>
> > > Date: Mon, 3 Sep 2018 15:45:22 +0200
> > >
> > > > On 03/09/2018 15:34:15+0200, Andrew Lunn wrote:
> > > >> > I suggest patches 1 and 8 go through MIPS tree, 2 to 5 and 11 go through
> > > >> > net while the others (6, 7, 9 and 10) go through the generic PHY subsystem.
> > > >>
> > > >> Hi Quentin
> > > >>
> > > >> Are you expecting merge conflicts? If not, it might be simpler to gets
> > > >> ACKs from each maintainer, and then merge it though one tree.
> > > >
> > > > There are some other DT changes for this cycle so those should probably
> > > > go through MIPS.
> > >
> > > No objection for this going through the MIPS tree, and from me:
> > >
> > > Acked-by: David S. Miller <davem@davemloft.net>
> >
> > What I meant was that 1/11 and 8/11 should go through MIPS because of
> > the potential conflicts. The other patches can go through net-next as
> > that will make more sense. Maybe Quentin can split the series in two,
> > one for MIPS and one for net if that makes it easier for you to apply.
>
> I'd be happy to take the .dts changes through the MIPS tree, though
> looking at them won't patch 1 break bisection?
>
> Since you remove the hsio reg entry it looks to me like
> mscc_ocelot_probe() will fail with -EINVAL (which comes from
> devm_ioremap_resource() with res=NULL) until patch 3.
>
That's correct.
> I'd feel more comfortable merging this piecemeal if it doesn't result in
> us breaking bisection for however long it takes for both the trees
> involved to be merged.
>
How do you want to proceed then?
Quentin
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply
* [PATCH bpf-next] bpf/verifier: properly clear union members after a ctx read
From: Edward Cree @ 2018-09-04 14:19 UTC (permalink / raw)
To: daniel, ast; +Cc: netdev
In check_mem_access(), for the PTR_TO_CTX case, after check_ctx_access()
has supplied a reg_type, the other members of the register state are set
appropriately. Previously reg.range was set to 0, but as it is in a
union with reg.map_ptr, which is larger, upper bytes of the latter were
left in place. This then caused the memcmp() in regsafe() to fail,
preventing some branches from being pruned (and occasionally causing the
same program to take a varying number of processed insns on repeated
verifier runs).
Signed-off-by: Edward Cree <ecree@solarflare.com>
---
Possibly something might need adding to __mark_reg_unknown() as well to
clear map_ptr/range, I'm not sure (though doing so did not affect the
processed insn count on the cilium programs).
kernel/bpf/verifier.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/kernel/bpf/verifier.c b/kernel/bpf/verifier.c
index f4ff0c569e54..49e4ea66fdd3 100644
--- a/kernel/bpf/verifier.c
+++ b/kernel/bpf/verifier.c
@@ -1640,9 +1640,9 @@ static int check_mem_access(struct bpf_verifier_env *env, int insn_idx, u32 regn
else
mark_reg_known_zero(env, regs,
value_regno);
- regs[value_regno].id = 0;
- regs[value_regno].off = 0;
- regs[value_regno].range = 0;
+ /* Clear id, off, and union(map_ptr, range) */
+ memset(regs + value_regno, 0,
+ offsetof(struct bpf_reg_state, var_off));
regs[value_regno].type = reg_type;
}
^ permalink raw reply related
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox