Subject: Re: [PATCH 03/19][v3] powerpc: Add memory entitlement capabilities to /proc/ppc64/lparcfg

From: Brian King <[email-masked]>
Date: Tue, 24 Jun 2008 09:23:57 -0500

Just a few minor nits.

> +/**
> + * h_get_mpp
> + * H_GET_MPP hcall returns info in 7 parms
> + */
> +int h_get_mpp(struct hvcall_mpp_data *mpp_data)
> +{
> +    int rc;
> +    unsigned long retbuf[PLPAR_HCALL9_BUFSIZE];
   ^^^^

Should be tabs instead of spaces in this function and a few others
in this patch file.

> +/**
> + * parse_mpp_data
> + * Parse out data returned from h_get_mpp
> + */
> +static void parse_mpp_data(struct seq_file *m)
> +{
> +    struct hvcall_mpp_data mpp_data;
> +    int rc;

Same here.

> +/**
> + * update_mpp
> + *
> + * Update the memory entitlement and weight for the partition.  Caller
> must
> + * spercify either a new entitlement or weight, not both, to be updated
      ^^^^^^^^

> + * since the h_set_mpp call takes both entitlement and weight as
> parameters.
> + */
> +static ssize_t update_mpp(u64 *entitlement, u8 *weight)
> +{
> +    struct hvcall_mpp_data mpp_data;

Tab/spacing here.

> @@ -270,6 +272,20 @@
>  };
>  #define HCALL_STAT_ARRAY_SIZE    ((MAX_HCALL_OPCODE >> 2) + 1)
> 
> +struct hvcall_mpp_data {
> +    unsigned long entitled_mem;
> +    unsigned long mapped_mem;
> +    unsigned short group_num;
> +    unsigned short pool_num;
> +    unsigned char mem_weight;
> +    unsigned char unallocated_mem_weight;
> +    unsigned long unallocated_entitlement;    /* value in bytes */
> +    unsigned long pool_size;
> +    long loan_request;

Might as well be specific here and call this a signed long.
Tab/spacing issue here as well.

-- 
Brian King
Linux on Power Virtualization
IBM Linux Technology Center