diff mbox series

[v3,09/15] unlzo: replace INIT

Message ID e9f80b21-dff6-d6f0-3e69-c42219a3aaa9@suse.com (mailing list archive)
State New, archived
Headers show
Series zstd decompression for DomU-s + fallout / consolidation | expand

Commit Message

Jan Beulich Jan. 26, 2021, 9:51 a.m. UTC
There's no need for this abstraction.

Requested-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Jan Beulich <jbeulich@suse.com>
---
v3: New.

Comments

Julien Grall April 15, 2021, 11:51 a.m. UTC | #1
Hi Jan,

On 26/01/2021 09:51, Jan Beulich wrote:
> There's no need for this abstraction.
> 
> Requested-by: Andrew Cooper <andrew.cooper3@citrix.com>
> Signed-off-by: Jan Beulich <jbeulich@suse.com>

Acked-by: Julien Grall <jgrall@amazon.com>

Cheers,

> ---
> v3: New.
> 
> --- a/xen/common/lzo.c
> +++ b/xen/common/lzo.c
> @@ -135,8 +135,8 @@
>    */
>   #define MAX_255_COUNT      ((((size_t)~0) / 255) - 2)
>   
> -int INIT lzo1x_decompress_safe(const unsigned char *in, size_t in_len,
> -                               unsigned char *out, size_t *out_len)
> +int __init lzo1x_decompress_safe(const unsigned char *in, size_t in_len,
> +                                 unsigned char *out, size_t *out_len)
>   {
>       unsigned char *op;
>       const unsigned char *ip;
> --- a/xen/common/unlzo.c
> +++ b/xen/common/unlzo.c
> @@ -57,7 +57,7 @@ static const unsigned char lzop_magic[]
>   #define HEADER_SIZE_MIN       (9 + 7     + 4 + 8     + 1       + 4)
>   #define HEADER_SIZE_MAX       (9 + 7 + 1 + 8 + 8 + 4 + 1 + 255 + 4)
>   
> -static int INIT parse_header(u8 *input, int *skip, int in_len)
> +static int __init parse_header(u8 *input, int *skip, int in_len)
>   {
>   	int l;
>   	u8 *parse = input;
> @@ -114,11 +114,11 @@ static int INIT parse_header(u8 *input,
>   	return 1;
>   }
>   
> -int INIT unlzo(unsigned char *input, unsigned int in_len,
> -	       int (*fill) (void *, unsigned int),
> -	       int (*flush) (void *, unsigned int),
> -	       unsigned char *output, unsigned int *posp,
> -	       void (*error) (const char *x))
> +int __init unlzo(unsigned char *input, unsigned int in_len,
> +		 int (*fill) (void *, unsigned int),
> +		 int (*flush) (void *, unsigned int),
> +		 unsigned char *output, unsigned int *posp,
> +		 void (*error) (const char *x))
>   {
>   	u8 r = 0;
>   	int skip = 0;
> 
>
diff mbox series

Patch

--- a/xen/common/lzo.c
+++ b/xen/common/lzo.c
@@ -135,8 +135,8 @@ 
  */
 #define MAX_255_COUNT      ((((size_t)~0) / 255) - 2)
 
-int INIT lzo1x_decompress_safe(const unsigned char *in, size_t in_len,
-                               unsigned char *out, size_t *out_len)
+int __init lzo1x_decompress_safe(const unsigned char *in, size_t in_len,
+                                 unsigned char *out, size_t *out_len)
 {
     unsigned char *op;
     const unsigned char *ip;
--- a/xen/common/unlzo.c
+++ b/xen/common/unlzo.c
@@ -57,7 +57,7 @@  static const unsigned char lzop_magic[]
 #define HEADER_SIZE_MIN       (9 + 7     + 4 + 8     + 1       + 4)
 #define HEADER_SIZE_MAX       (9 + 7 + 1 + 8 + 8 + 4 + 1 + 255 + 4)
 
-static int INIT parse_header(u8 *input, int *skip, int in_len)
+static int __init parse_header(u8 *input, int *skip, int in_len)
 {
 	int l;
 	u8 *parse = input;
@@ -114,11 +114,11 @@  static int INIT parse_header(u8 *input,
 	return 1;
 }
 
-int INIT unlzo(unsigned char *input, unsigned int in_len,
-	       int (*fill) (void *, unsigned int),
-	       int (*flush) (void *, unsigned int),
-	       unsigned char *output, unsigned int *posp,
-	       void (*error) (const char *x))
+int __init unlzo(unsigned char *input, unsigned int in_len,
+		 int (*fill) (void *, unsigned int),
+		 int (*flush) (void *, unsigned int),
+		 unsigned char *output, unsigned int *posp,
+		 void (*error) (const char *x))
 {
 	u8 r = 0;
 	int skip = 0;