kernel: bump 4.14 to 4.14.159
[openwrt/staging/luka.git] / target / linux / apm821xx / patches-4.14 / 020-0019-crypto-crypto4xx-overhaul-crypto4xx_build_pd.patch
index 023f63638fb5b1fd83be174d9c01d2b3b2d64953..7efb0e699f3e2d23d8e79041cdc6d26dc9a1d1e4 100644 (file)
@@ -263,7 +263,7 @@ Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
  /**
   * alloc memory for the gather ring
   * no need to alloc buf for the ring
-@@ -520,18 +514,16 @@ static void crypto4xx_copy_pkt_to_dst(st
+@@ -516,18 +510,16 @@ static void crypto4xx_copy_pkt_to_dst(st
        }
  }
  
@@ -285,7 +285,7 @@ Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
  }
  
  static void crypto4xx_ret_sg_desc(struct crypto4xx_device *dev,
-@@ -600,7 +592,7 @@ static u32 crypto4xx_ahash_done(struct c
+@@ -596,7 +588,7 @@ static u32 crypto4xx_ahash_done(struct c
        ahash_req = ahash_request_cast(pd_uinfo->async_req);
        ctx  = crypto_tfm_ctx(ahash_req->base.tfm);
  
@@ -294,7 +294,7 @@ Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
                                     crypto_tfm_ctx(ahash_req->base.tfm));
        crypto4xx_ret_sg_desc(dev, pd_uinfo);
  
-@@ -660,17 +652,17 @@ static u32 get_next_sd(u32 current)
+@@ -656,17 +648,17 @@ static u32 get_next_sd(u32 current)
                return 0;
  }
  
@@ -317,7 +317,7 @@ Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
        struct ce_gd *gd;
        struct ce_pd *pd;
        u32 num_gd, num_sd;
-@@ -678,8 +670,9 @@ u32 crypto4xx_build_pd(struct crypto_asy
+@@ -674,8 +666,9 @@ u32 crypto4xx_build_pd(struct crypto_asy
        u32 fst_sd = 0xffffffff;
        u32 pd_entry;
        unsigned long flags;
@@ -329,7 +329,7 @@ Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
        u32 gd_idx = 0;
        bool is_busy;
  
-@@ -693,7 +686,7 @@ u32 crypto4xx_build_pd(struct crypto_asy
+@@ -689,7 +682,7 @@ u32 crypto4xx_build_pd(struct crypto_asy
                num_gd = 0;
  
        /* figure how many sd is needed */
@@ -338,7 +338,7 @@ Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
                num_sd = 0;
        } else {
                if (datalen > PPC4XX_SD_BUFFER_SIZE) {
-@@ -764,37 +757,27 @@ u32 crypto4xx_build_pd(struct crypto_asy
+@@ -760,37 +753,27 @@ u32 crypto4xx_build_pd(struct crypto_asy
        }
        spin_unlock_irqrestore(&dev->core_dev->lock, flags);
  
@@ -389,7 +389,7 @@ Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
                /* get first gd we are going to use */
                gd_idx = fst_gd;
                pd_uinfo->first_gd = fst_gd;
-@@ -803,27 +786,30 @@ u32 crypto4xx_build_pd(struct crypto_asy
+@@ -799,27 +782,30 @@ u32 crypto4xx_build_pd(struct crypto_asy
                pd->src = gd_dma;
                /* enable gather */
                sa->sa_command_0.bf.gather = 1;
@@ -430,7 +430,7 @@ Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
                /*
                 * Disable gather in sa command
                 */
-@@ -834,25 +820,24 @@ u32 crypto4xx_build_pd(struct crypto_asy
+@@ -830,25 +816,24 @@ u32 crypto4xx_build_pd(struct crypto_asy
                pd_uinfo->first_gd = 0xffffffff;
                pd_uinfo->num_gd = 0;
        }
@@ -463,7 +463,7 @@ Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
                u32 sd_idx = fst_sd;
                nbytes = datalen;
                sa->sa_command_0.bf.scatter = 1;
-@@ -866,7 +851,6 @@ u32 crypto4xx_build_pd(struct crypto_asy
+@@ -862,7 +847,6 @@ u32 crypto4xx_build_pd(struct crypto_asy
                sd->ctl.done = 0;
                sd->ctl.rdy = 1;
                /* sd->ptr should be setup by sd_init routine*/
@@ -471,7 +471,7 @@ Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
                if (nbytes >= PPC4XX_SD_BUFFER_SIZE)
                        nbytes -= PPC4XX_SD_BUFFER_SIZE;
                else
-@@ -877,19 +861,23 @@ u32 crypto4xx_build_pd(struct crypto_asy
+@@ -873,19 +857,23 @@ u32 crypto4xx_build_pd(struct crypto_asy
                        /* setup scatter descriptor */
                        sd->ctl.done = 0;
                        sd->ctl.rdy = 1;