[U-Boot] [PATCH v2 1/2] Introduce generic TPM support in u-boot

Vadim Bendebury vbendeb at chromium.org
Sun Oct 16 16:57:51 CEST 2011


Wolfgang Denk,

On Sun, Oct 16, 2011 at 12:35 AM, Wolfgang Denk <wd at denx.de> wrote:
> Dear Vadim Bendebury,
>
> In message <CANy1bu+DZmD_Z=AU8LdTUy7ewHfwMU-8PvH1OA1jba9Tz1xuxA at mail.gmail.com> you wrote:
>>
>> >> I am not sure what is wrong with a short macro in this case - is this
>> >> against the coding style?
>> >
>> > It doesn't do typechecking.
>>
>> but the code around it does, doesn't it?
>
> I explained this yesterday, too.  Functions are preferred over macros.
> In this case ther eis no reason not to use a function.
>
>> Sorry, as I said, I am new here: how does this work on this project -
>> does the submitter have to agree to all reviewer's comments? Can I ask
>
> No, you don't have to agree.  But we also don't have to accept code
> that we don't like ;-)
>

certainly, but wouldn't you risk to throw the baby out with the bath
water this way? ;-)

Also, what about situations when one reviewer requests a certain
implementation and another one finds it inappropriate?

>> somebody else to confirm that using a macro in this case in
>> inappropriate?
>
> I already did.
>

Thank you, I will fix this.

Can you please also confirm that having a structure with a single
element as an array is "weird" and must be changed to passing around a
pointer to a single element without the size (or maybe the idea is
that the pointer AND the size need to be passed around)?

Are macros acceptable to wrap input output with debug messages, as was
suggested earlier on this list, or should I replace each macro with
two inline functions?

Please advise,
cheers,
/vb


>
> Best regards,
>
> Wolfgang Denk
>
> --
> DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
> HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
> Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
> The average woman would rather have beauty than brains,  because  the
> average man can see better than he can think.
> _______________________________________________
> U-Boot mailing list
> U-Boot at lists.denx.de
> http://lists.denx.de/mailman/listinfo/u-boot
>


More information about the U-Boot mailing list