Josh Eidelson and Alyssa Rosenberg are having a discussion about the humor about race, ethnicity, and gender on "30 Rock", and it's well worth reading. All I'll say is that I think both of them have a point. Alyssa's right that "30 Rock" is sometimes very incisive, and Josh is right that the episode where Tracy and Liz have to follow the same rules as everyone else was a stupid episode that didn't really have a point. Politically, "30 Rock" is all over the map, sometimes being incredibly subversive and sometimes graying into reactionary politics, and often in the same episode. The show is grounded not in satire but in characterization, so I don't really expect cutting edge political satire from it. But Josh's follow-up definitely outlines some of the things about the show that bother me, and I'll add that it's annoying that Jack is always right.
But one thing that Alyssa hints at that the show does consistently well on in the subversion department is its portrayal of mental illness. I struggled with depression when I was younger, and it's an experience that leaves me incredibly sad that there's very little good humor out there about Teh Crazy. Now, some people think the only appropriate response to the tragedy of mental illness is to be very serious about it, lest you be accused of being insensitive, but that's always struck me as condescending. Sure, jokes about mental illness that reduce and objectify the mentally ill suck, and I think the fear of this causes most comedy writers to mostly avoid the issue. Oh, comedy leans heavily on neurosis, sure, but not mental illness. "30 Rock" also leans heavily on neurosis, since nearly everyone on the show is neurotic, at least amongst the main characters. (Probably the only ones who aren't are Kenneth, Gris, and Dot Com.) Everyone except Tracy Jordan, who is, as Alyssa notes, "straight-up mentally ill!" You have a lot of kooky or neurotic characters on sitcoms, but mental illness is invisible. Just even admitting that it's real and it's serious is subversive.
Of course, we don't know exactly what kind of mental illness Tracy's suffering from, because one of the running gags on the show is that he's got one of those Hollywood doctors who is hired because of his incompetence and freedom with the prescription pad. Likely, he's bipolar or manic depressive. He sinks into weeping temper tantrums with very little provocation, and he goes on manic streaks, running around town, staying up all night. His prescriptions get all screwed up, and he goes completely batshit.
And they have a lot of fun with it. But what they don't do is use it to dehumanize Tracy or suggest his illness is the sum total of who he is. On the flip side, they do something really subversive, which is they've created a character who is both mentally ill and still functions---albeit with problems---in the real world. You know, like most people with mental illness do. He's not only competent at his job, he's the glue that holds the show together. He has a family and friends and a life, and even though he's selfish and constantly fucking up his family life, you do get some episodes where he deals---again, in the absurd way the show treats everything---with his regret that his impulsiveness and mood swings (combined with his selfishness) affect his family. And above all, as Alyssa points out, his mental illness is not portrayed as making him stupid.
On the contrary, to build on Alyssa's point, one of the running jokes on the show is that people underestimate Tracy. And not just because of racism, though that's a large part of it. It's often because they judge him because of his mental illness and realize that being mentally ill doesn't necessarily mean that you've lost your ability to think or perceive reality. Okay, sometimes. That's the nature of the beast, after all. But the other characters somewhat understandably have trouble separating Tracy's genuine delusions of grandeur from his accurate assessments of his own formidable abilities, and it keeps hilariously biting them in the ass. For me, though, I'm stoked to see someone with an out and out mental illness being shown as someone with formidable abilities, and it not being some kind of one shot Very Special Episode serious, condescending bullshit that implies that creative people with mental illnesses are necessarily idiot savants.
They also play with and portray something that a lot of creative people who suffer from mental illness worry about, which is the fear that they owe their creative powers or their success to their illness. "30 Rock" never succumbs to the urge to do a dreary sentimental portrayal of Tracy's fears. Instead, he flails comically all over the place, swinging between attempts to actually do something about all his problems and deciding that he prefers the devil he knows, because he's utterly convinced his star hangs on his nutty, manic behavior. The show darkly implies that he's not wrong to think this, either, because Americans really do have a fascination with celebrity dysfunction that shades into encouraging it, with people like Britney Spears and Lindsay Lohan as exemplars of the issue. All of this means that it's pretty well-established that Tracy isn't going to get better, but I appreciate that, too. A whole lot of mental illness is chronic, and people will struggle their whole lives with it. Which means TV producers shy away from it because there's no dramatic arc, and comedy especially avoids it because it's a depressing thought. Unless you're a very dark, cynical comedy, that is, and "30 Rock" is definitely that.
By employing Tracy's mental illness as a darkly comic device, the writers and Tracy Morgan himself have created the only TV portrayal I can think of that shows mental illness in roughly the light that most people experience it. It's frustrating, but not the end of the world. It's chronic but manageable. It informs his personality, but it's not the sum total of his personality. And he has the same ambivalent feelings a lot of people have about their own illnesses, where they worry that they'd lose part of themselves if they got better. And by laughing about it, they aren't condescending to mentally ill people. On the contrary, they are mainstreaming them, instead of the usual TV strategy of erasure and silencing through condescending portrayals before shuffling the character off-screen.