py: Allow retrieving a function's __name__.

Disabled by default.  Enabled on unix and stmhal ports.
diff --git a/py/mpconfig.h b/py/mpconfig.h
index e8f7cc8..094d8d7 100644
--- a/py/mpconfig.h
+++ b/py/mpconfig.h
@@ -359,6 +359,11 @@
 /*****************************************************************************/
 /* Fine control over Python builtins, classes, modules, etc                  */
 
+// Whether to implement attributes on functions
+#ifndef MICROPY_PY_FUNCTION_ATTRS
+#define MICROPY_PY_FUNCTION_ATTRS (0)
+#endif
+
 // Whether str object is proper unicode
 #ifndef MICROPY_PY_BUILTINS_STR_UNICODE
 #define MICROPY_PY_BUILTINS_STR_UNICODE (0)