Re: [PATCH] Intel Manageability Engine Interface driver

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Anas Nashif <nashif@...>
Cc: <linux-kernel@...>, Marek Dabek <marek.dabek@...>
Date: Monday, October 22, 2007 - 2:40 pm

On Mon, 22 Oct 2007 13:22:38 -0400 Anas Nashif <nashif@linux.intel.com> wrote:


Please get the patches mailed out somehow.  Consider splitting the patch
up.  I think you could send it as-is (200k will fit, I believe) but it's
rather too large to review effectively.

The code looks good from a quick scan.  Immediate impressions from a
quick scan, mainly trivia:



- Consider using open-coded "0" in place of ESUCCESS

- Remove #pragme pack(1), use __attribute__((packed))

- Why does a new driver have "additional char device for legacy mode"?

- Remove the INFO(), ERR() and WARN() macros, just open-code the printk calls

- Remove the commented-out DEF_PARM, HECI_DEBUG, any others

- You can't have a global variable called "debug"!

- Remove private definitions of TRUE and FALSE.  Use standard "true" and
  "false" or just open-code 0 and 1.

- This:

+     /**
+      * virtual void GetParam(const char* UserParam);
+      * read write messages to/from heci fw
+      */

  appears to be dead code, should be called get_param, should use
  tabstops not spaces

- These:

+#define SHUTDOWN_METHOD(method) .shutdown = method,
+#define HECI_REBOOT_NOTIFIER(reboot_notifier, driver, reboot_function)
+#define REGISTER_REBOOT_NOTIFIER(reboot_notifier)
+#define UNREGISTER_REBOOT_NOTIFIER(reboot_notifier)
+#define heci_reboot_notifier

  will be unpopular.  See if they can be removed via suitable means?

- heci_init.c has these:

+/**
+ *  heci init function prototypes
+ */
+int host_start_message(struct iamt_heci_device *dev);
+int host_enum_clients_message(struct iamt_heci_device *dev);
+int allocate_me_clents_storage(struct iamt_heci_device *dev);
+void heci_disable(struct iamt_heci_device *dev);
+void host_init_wd(struct iamt_heci_device *dev);
+void host_init_legacy(struct iamt_heci_device *dev);
+int heci_wait_event_int_timeout(struct iamt_heci_device *dev, long timeout);

  which are extern-declarations-in-C which checkpatch failed to detect. 
  They should be placed in a header file or just removed.

- please review all global symbols, check that they really do need to be
  global, and that they have suitable names (ie: not like "debug")

- mysterious msleep(100) in host_start_message()?  Needs a comment.

- Please prefer to put a blank line between the declaration of locals and
  the start of code in each function.

- Here:

+		if (0 == memcmp(&heci_wd_guid,

  we boringly prefer "if (foo == 0)" rather than "if (0 == foo)".  (lots
  of places).

- The changelog could do with some expansion.  What is "Intel(R)
  Manageability Engine (ME) firmware"?  Why do we want to include this code
  in Linux?  What value has it to our users, etc?  Bascially: tell us more
  stuff.


-
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH] Intel Manageability Engine Interface driver , Anas Nashif, (Mon Oct 22, 1:22 pm)
Re: [PATCH] Intel Manageability Engine Interface driver, Maxim Levitsky, (Mon Oct 22, 6:30 pm)
Re: [PATCH] Intel Manageability Engine Interface driver, Gerd Hoffmann, (Thu Oct 25, 5:33 am)
Re: [PATCH] Intel Manageability Engine Interface driver, Maxim Levitsky, (Tue Oct 23, 9:42 am)
Re: [PATCH] Intel Manageability Engine Interface driver, Andrew Morton, (Mon Oct 22, 2:40 pm)
Re: [PATCH] Intel Manageability Engine Interface driver, Lennart Sorensen, (Tue Oct 23, 11:04 am)
Re: [PATCH] Intel Manageability Engine Interface driver, Andrew Morton, (Tue Oct 23, 12:32 pm)
Re: [PATCH] Intel Manageability Engine Interface driver, Arjan van de Ven, (Tue Oct 23, 12:23 pm)
Re: [PATCH] Intel Manageability Engine Interface driver, Lennart Sorensen, (Tue Oct 23, 2:05 pm)
Re: [PATCH] Intel Manageability Engine Interface driver, Roland Dreier, (Tue Oct 23, 2:22 pm)
Re: [PATCH] Intel Manageability Engine Interface driver, Lennart Sorensen, (Tue Oct 23, 3:35 pm)
Re: [PATCH] Intel Manageability Engine Interface driver, Bernd Petrovitsch, (Wed Oct 24, 5:00 am)
Re: [PATCH] Intel Manageability Engine Interface driver, Andrew Morton, (Tue Oct 23, 12:25 pm)
Re: [PATCH] Intel Manageability Engine Interface driver, Maxim Levitsky, (Tue Oct 23, 9:36 am)
Re: [PATCH] Intel Manageability Engine Interface driver, Xavier Bestel, (Mon Oct 22, 2:28 pm)